Posted on: 04/25/07 10:51am
By: Anonymous (Will)
I'm importing an RSS feed on my site but every time there's a single quote it gets written as a question mark. For example,
John's cat
would come across as:
John?s cat
Is there an option or something I can use to have geeklog escape the single quote's properly, or might this be a problem with the originating feed?
Thanks again for providing the best CMS out there,
Will
Re: Displaying single quotes properly in imported RSS feeds
Posted on: 04/25/07 01:56pm
By: Dirk
URL?
Often, the single quote is not really a single quote but some other special character that just looks like one. And in that case, the correct encoding of the feed is important.
bye, Dirk
Re: Displaying single quotes properly in imported RSS feeds
Posted on: 04/25/07 04:10pm
By: Anonymous (Will)
URL of the rss feed is:
http://www.liberal.ca/rss/news_e.aspx?type=news
I see what you mean now. They're using those MS style single quotes. Any tips for getting around that?
replacing curly quotes in RSS feeds
Posted on: 04/26/07 07:46pm
By: Anonymous (Will)
Has anyone else had to convert curly quotes in an RSS feed to regular quotes? I've tried inserting functions at a few places but can't seem to make it work. Any help would be greatly appreciated.
Re: Displaying single quotes properly in imported RSS feeds
Posted on: 04/26/07 11:49pm
By: mevans
Will,
I tested the RSS URL you gave above on my site which uses UTF-8 encoding and it displayed fine. My guess is that the feed is also using UTF-8 as the encoding and when displaying on a non-UTF-8 (iso-8859-1) site, the issue appears.
You might consider converting your site to UTF-8. It is a pretty straight forward process, but it does have some risk since you need to dump, drop and reload your database. I've written up how I did my conversion
here[*1] . You might give it a read and see if you want to give it a shot.
Good luck,
Mark
Re: Displaying single quotes properly in imported RSS feeds
Posted on: 04/28/07 04:47am
By: Anonymous (Will)
Mark,
Thank you very much for pointing me in the right direction. There hadn't been a lot of content posted yet so I just deleted the database, made a new one set up for unicode, reinstalled Geeklog, and reposted the stories. This worked out very well because it's a Canadian site and needed to display french accents and such anyway. And the added bonus is that now I can use any international symbols for currency, scientific notation, and so on. I'm happy and grateful to you.
And this will certainly be the very last time I set up Geeklog using the default language settings. Might be a good idea to make the default utf8-english in the next version.
Finished version is at http://haldimandnorfolkliberals.com