Monkey Raptor

Monday, February 18, 2013

Converting ASCII character to HTML character with Blogger editor

Did you know that Blogger already has a built-in text character to HTML/XML (and vice versa) converter?

Therefore, if you want to put, for instance, AdSense codes inside the blogger HTML/XML body, you don't have to go far searching for online code interpreter (or parser).

Just use the post editor, and it's done.

Copy your code to Compose mode, then go to HTML mode, it's automatically converted.

You can see an example below.

You can see at the snapshots that some of the characters were converted.

The HTML/XML can only 'use'  the < and > as that &lt; and &gt;. Why is that? Because < and > along with other predefined characters are already used in delimit markup for tags, such as <div>, </head> and so on. Here's a source of reading on W3C.

If for some reason you have an HTML code snippet, and you want to convert it back to normal text, you can put it on the blogger post HTML editor and click the Compose. It will be converted back to normal characters.

That is all. Thanks for visiting.

Update :
Monkey Raptor has created a tool for this - Online Text to HTML Converter
Converting ASCII character to HTML character with Blogger editor

No comments

Post a Comment

Tell me what you think...