This blog site is not meant to be any information that is distributed to the general public. It is to serve as shared documentation between the DNSTC developers; however, if you find something useful and would like to use it, go right ahead.

Thursday, January 26, 2012

Garbage Characters Being Displayed from Blog Posts

imageThe following describes an issue that we had with pulling RSS feeds from WordPress and displaying them on web pages and how we resolved the problem.  The main issue was that some characters where being displayed as garbage on the screen.  It took many months of research and testing out different things to get this issue resolved.



The main issue lied within the character encoding of the page where there information was being displayed.  The information coming from WordPress and the RSS feed was encoded with UTF-8 which allows for more than 128 ASCII characters; whereas, the HTML page it was being display on was encoded with iso-8859-1.


Change the encoding on the HTML page to UTF-8.  This fixes the issue and clears up all of the garbage characters.

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

Additional Resources

No comments:

Post a Comment