Display HTML code on a website
June 9th, 2008
HTML is used to design a website but what if you want to display a sample HTML code in a website?? The browser will consider your sample code just as the rest of the HTML code and parse it in a similar way, removing all the tags before it displays the content on the website.
To display some HTML code, you need to use escape characters for all the special characters defined in HTML. The following link has a HTML Encoder/Decoder which can generate the code that should be inserted to achieve the desired HTML code form as output.
Just input the code you desire to display and copy paste the encoded code in your HTML file.
Enjoy !!
Hi, gr8 post thanks for posting. Information is useful!
am glad this information was useful to you.
I think I will try to recommend this post to my friends and family, cuz it’s really helpful.