Monday, September 29, 2008

How To Display HTML Tags In a Blogger Post

To actually display a tag you need to HTML encode all of the the '<'s.  This is done by replacing '<' with '&lt;'.  And that's it!

as a side note if you want to display '&lt;'. as I just did you need to encode the '&' by replacing it with '&amp;'.  This continues recursively.

I have foud that bloggers spell check can mess this up by HTML encoding it again (it did this to me once), so you may want to enter these after spellcheck.

0 comments:

 
Add to Technorati Favorites Video Games Blog
Blog Directory