+ 1
How can this code lies in a regular manner?
8 Answers
+ 2
You mean why it doesn't show an error, even though you haven't closed the <li> tags.
This happens because HTML is not as strict as other languages and some browsers will just ignore that problem. But remember, not every browser will tolerate such errors.
+ 2
If you try every browser you will definetly find one.ā
But the idea is that we have to educate the future programmers with good programming practises, so they will write clean and correct codes.š
+ 2
š
+ 1
Thanks
+ 1
LĪµd10 DĪµda Name one browser that won't tolerate it.
+ 1
i dont know sir, please tell
+ 1
LĪµd10 DĪµda Google doesn't agree with you: https://google.github.io/styleguide/htmlcssguide.html#HTML_Formatting_Rules .
The reason is simple: the HTML standard specifies the following tags as optional to close: li, html, head, body, p, dt, dd, option, thead, th, tbody, tr, td, tfoot, colgroup. You can not close any of the above and NO standard browser will complain.
+ 1
@Vlad Serbu
Thanks for the precious informationš