Re: Stripping weird characters from RSS feed

From: Date: Mon, 23 Jan 2006 22:27:38 +0000
Subject: Re: Stripping weird characters from RSS feed
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-229135@lists.php.net to get a copy of this message
Paul Nowosielski wrote: > I have a RSS feed aggregater that grabs RSS from the net then stores it > to a MySQL database. Once in a while I get feeds with weird characters > look really bad. > Ghana: Country Loses ¢20.2bn Through Music Piracy This looks like a case of reading the file using the wrong character encoding. Find out what encoding the file is in (the HTTP header /should/ tell you, if it doesn't then the XML prolog should), and use that. Of course, its possible the encoding information sent with the file is wrong, in which case you could try guessing (and should certainly prod at the feed provider to get them to fix their mistakes). -- David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/> Home is where the ~/.bashrc is

« previous php.general (#229135) next »