Page 1 of 2

Published Articles RSS feed does not display some caracters

Posted: 05 Apr 2013, 17:40
by Monfreid
Hello,

I don't know if I should post this here or if the subject is clear enough but in short, for exemple

The article title is this:

Kimi Räikkönen et l'argent (1/2)

but in the RSS feed of the Published Articles it's like that:

Kimi Räikkönen et l'argent (1/2)

it happens with ' or "

Is there any way to change this please?

Thank you

Re: Published Articles RSS feed does not display some caract

Posted: 05 Apr 2013, 18:18
by ArchCarrier
It also happens with   in the feed from longreads.com:

Image

Re: Published Articles RSS feed does not display some caract

Posted: 12 Apr 2013, 14:29
by Monfreid
Hello,

any idea what could be the problem here?

thank you

Re: Published Articles RSS feed does not display some caract

Posted: 12 Apr 2013, 15:55
by ArchCarrier
This small change fixed the problem for me, at least for the Longreads feed:

In classes/feeds.php, change line 549 (current GitHub version)

Code: Select all

$line["title"] .

to

Code: Select all

html_entity_decode($line["title"]) .

Re: Published Articles RSS feed does not display some caract

Posted: 12 Apr 2013, 15:59
by fox
I kinda doubt that it's a good idea to blindly decode entities and hope for the best though.

Re: Published Articles RSS feed does not display some caract

Posted: 12 Apr 2013, 16:13
by ArchCarrier
What could be the negative effects?

Re: Published Articles RSS feed does not display some caract

Posted: 12 Apr 2013, 16:30
by fox
Can't think of any. It's a feeling. Upon some investigation it seems that simplepie gives tt-rss encoded entities so there's no double-encoding done. I suppose it's possible to just decode entities when the entry is being imported to nip this in the bud.

I'll add the change and we'll see if anything gets horribly broken.

Re: Published Articles RSS feed does not display some caract

Posted: 12 Apr 2013, 17:01
by ArchCarrier
Great, thanks!

Re: Published Articles RSS feed does not display some caract

Posted: 26 Apr 2013, 15:33
by Monfreid
ArchCarrier wrote:This small change fixed the problem for me, at least for the Longreads feed:

In classes/feeds.php, change line 549 (current GitHub version)

Code: Select all

$line["title"] .

to

Code: Select all

html_entity_decode($line["title"]) .


I've just tried the same but it didn't work for me :-(

Re: Published Articles RSS feed does not display some caract

Posted: 26 Apr 2013, 16:18
by ArchCarrier
What feed are you having troubles with? And which TTRSS version are you using? Fox said he was going to add the fix, so you can try the trunk version of feeds.php

Re: Published Articles RSS feed does not display some caract

Posted: 26 Apr 2013, 17:10
by Monfreid
ArchCarrier wrote:What feed are you having troubles with? And which TTRSS version are you using? Fox said he was going to add the fix, so you can try the trunk version of feeds.php


The only feeds I have problem with are the "starred articles" and "published articles" feeds. I'm using TT RSS 1.7.8.

For example:

it looks ok on TT RSS

Image

but not on the Published RSS feed

Image

I will replace the feeds.php file with the trunk version as you said and see how it works.

Thank you

Re: Published Articles RSS feed does not display some caract

Posted: 26 Apr 2013, 22:34
by ArchCarrier
I don't use the Published feeds, so I can't really help with that one. Maybe the code for those feeds is in another file?

Re: Published Articles RSS feed does not display some caract

Posted: 29 Apr 2013, 16:09
by Monfreid
It's still not working for me, even after replacing the file feeds.php with the one found on github.
I hope this could be fixed in 1.7.9.
Maybe there is not a lot of people using the published articles feeds but I'm one of them and I use them intensively in Google Reader for my 2 websites. without this, maintaining my websites will be much more difficult. These websites generates some revenue (not a lot) to me so having this working would be great. I would give a donation for the fix :-)
Thanks

Re: Published Articles RSS feed does not display some caract

Posted: 29 Apr 2013, 16:26
by xtaz
The usual advice with trying a feature from trunk is to get ALL files from the trunk and not just cherry-pick one or two of them. The fix might not just be in feeds.php. Could be part of several different files. Plus if you just update a couple of files then they might not play nicely any more with the older files. Either wait for 1.7.9 or try the whole trunk.

Re: Published Articles RSS feed does not display some caract

Posted: 29 Apr 2013, 16:33
by fox
Give donation to simplepie developers so their feed library would stop fucking up the content on import. Read the FAQ entry one. In red.