Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid characters in dc:creator #392

Closed
RasmusMalver opened this issue Mar 7, 2015 · 2 comments
Closed

Invalid characters in dc:creator #392

RasmusMalver opened this issue Mar 7, 2015 · 2 comments

Comments

@RasmusMalver
Copy link

Problem

Recently an increasing number of feeds are using invalid characters in the dc:creator tag. Specifically when the author has a non-English name, e.g. Stéphanie. Somewhere in the creation of the feed, a poorly written app translates this to <dc:creator>St&eacute;phanie</dc:creator>.

Unfortunately this renders the entire XML document invalid, and SimplePie can't handle it, before the one post with one invalid tag is pushed from the feed.

Proposed solution

I know the problem is caused by a third party using bad software, but could we not make a fall-back for SimplePie, where it tries to html_entities_decode() the contents of the guilty tag, before collapsing?

Has anybody tried a quick-fix? E.g. stripping tags from feeds, before serving them to SimplePie?

Error code

This XML document () is invalid, likely due to invalid characters. XML error: not well-formed (invalid token)

To replicate

Try parsing http://feeds.feedburner.com/Ikeahacker

@Alkarex
Copy link
Contributor

Alkarex commented Apr 6, 2015

Could you please give a try to #400 ?

@mblaney
Copy link
Member

mblaney commented Mar 18, 2016

hi @rasmis this looks ok to me now, please try again with the latest version.

@mblaney mblaney closed this as completed Mar 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants