The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> IfThisThanThat conditional statement HTML
RtvOost
post Apr 15 2022, 07:14 AM
Post #1





Group: Members
Posts: 1
Joined: 15-April 22
Member No.: 28,317



Im trying to make an IfThisThanThat statement in HTML code but my link that should show up doesn't show up, does anybody know how to write the code?

This is what i wrote:

<textarea name="Awnser1" id="1"></textarea>
<input type="submit"
{% if awnser1 = 1234 %}
<a href = "Right.html">Right</a>
{% else %}
<h2>Wrong</h2>
{% endif %} id="1">
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
CharlesEF
post Apr 15 2022, 02:44 PM
Post #2


Programming Fanatic
********

Group: Members
Posts: 1,981
Joined: 27-April 13
From: Edinburg, Texas
Member No.: 19,088



HTML doesn't have a 'IfThisThanThat' structure. You need to use either server side or client side code. I don't see any use for a question/answer using Javascript, since the answer can be seen by viewing the source.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Apr 15 2022, 06:52 PM
Post #3


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



What language is that that you are trying to use?
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
CharlesEF
post Apr 16 2022, 10:31 PM
Post #4


Programming Fanatic
********

Group: Members
Posts: 1,981
Joined: 27-April 13
From: Edinburg, Texas
Member No.: 19,088



I have seen '{% xxx %}' used in Django templates.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
2 User(s) are reading this topic (2 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 29th March 2024 - 12:29 AM