Option tag does not require an ending tag ? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 8

Option tag does not require an ending tag ?

In html challenges, the answer used to be True, but suddenly changes to False! https://code.sololearn.com/WoHqlWnv9hzz/?ref=app What is your opinion about?

19th May 2018, 5:23 PM
⏩▶Clau◀⏪
⏩▶Clau◀⏪ - avatar
6 Answers
+ 9
when using select or datalist option tag is single With optgroup its double   <optgroup label="Swedish Cars">     <option value="volvo">Volvo</option>     <option value="saab">Saab</option> </optgroup> All in all that html question is a very bad one
19th May 2018, 5:40 PM
᠌᠌Brains[Abidemi]
᠌᠌Brains[Abidemi] - avatar
+ 7
Yes, you are 100% right, i have experienced it a day before, in fact option tag requires closing tags, thanks for raising this issue,😃
19th May 2018, 5:37 PM
Sanjeet
Sanjeet - avatar
+ 7
In optgroup option tag must be closed, but in select it doesn't,😃
19th May 2018, 5:39 PM
Sanjeet
Sanjeet - avatar
+ 6
Brains thanks for making it clear, sololearn community must do something about that,😃
19th May 2018, 5:45 PM
Sanjeet
Sanjeet - avatar
+ 5
Brains thanks for illuminate me 😁
19th May 2018, 6:19 PM
⏩▶Clau◀⏪
⏩▶Clau◀⏪ - avatar
+ 4
<option> tag requires closing tag, like this: <select id = “favouriteCodingLanguage”> <option>HTML</option> <option>CSS</option> <option>JavaScript</option> <option>PHP</option> <option>Python</option> <option>C++</option> <option>C#</option> <option>C</option> <option>SQL</option> <option>Java</option> <option>Ruby</option> <option>Swift</option> </select>
20th May 2018, 8:59 AM
Rowsej
Rowsej - avatar