How to Change Encoding in MagpieRSS





Including RSS feeds in your website is a good idea, and MagpieRSS is probably the most popular tool. The default encoding for this tool, however, is in “ISO-8859-1″, which means it won’t be able to display Unicode characters properly. Therefore, some tweaking is needed if you want to use RSS feeds in languages other than English.

To read characters in Unicode, you’ll need to change the MAGPIE_OUTPUT_ENCODING variable in the rss_fetch.inc file.

Before

if ( !defined(‘MAGPIE_OUTPUT_ENCODING’) ) {
define(‘MAGPIE_OUTPUT_ENCODING’, ‘ISO-8859-1′);
}

After

if ( !defined(‘MAGPIE_OUTPUT_ENCODING’) ) {
define(‘MAGPIE_OUTPUT_ENCODING’, ‘UTF-8′);
}

Tags: Tags: ,