Special Characters need to be escaped? What does this mean and why am I receiving the error message yet the code is working?

Hi Guys!

I am currently working through the Introduction to HTML course and coming across some error messages. They are not actually effecting the output though and the course is accepting my code as correct so I am just curious what do they mean and why am I receiving?

I am at the section showing you how to insert a video to a web page. With the opening video tag I am seeing a message that says “special characters must be escaped” and with the closing tag I am seeing a message that says “Tags must be paired, no start tag.” It’s a bit confusing as the video is working. But my concern is that if I was to do this outside of codecademy it would not work. Also just general curiosity!

The link to the course i am on : https://www.codecademy.com/courses/learn-html/lessons/intro-to-html/exercises/videos-html

The code:

<video src="https://s3.amazonaws.com/codecademy-content/courses/freelance-1/unit-1/lesson-2/htmlcss1-vid_brown-bear.mp4" width="320" height="240"controls>Video not supported</video>

Thanks in advance for your help!

“Tags must be paired, no start tag.” - Most tags in HTML are in pairs (or self closing), i.e. <div> and </div>. This error is suggesting you have an extra closing tag of something.
“special characters must be escaped” - < and > are special characters in html (they are used to create the tags), so shouldn’t be used directly in text.

These two messages combined sugged that you have missed a closing tag on an something and so it isn’t recgonising the opening tag of the next thing, causing to moan about an unpaired closing tag.

1 Like

Adding to @jagking reply is that the reason why it is still working is because modern day browsers are that smart they read through the error and display the video nevertheless.

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.