nmdias / FeedKit

An RSS, Atom and JSON Feed parser written in Swift
MIT License
1.19k stars 173 forks source link

Special character numerical values #72

Closed codingmanu closed 5 years ago

codingmanu commented 5 years ago

Hi!

I'm having an issue parsing a RSS feed where some characters inside a CDATA area (description field, specifically) are being parsed as the numerical value instead of the character itself.

Not sure if this is the feed's fault or the parser's fault.

Examples:

&#8230 ; instead of ... (one character) &#160 ; instead of white space &#8211 ; instead of long dash &#38 ; instead of &

This is coming from a Wordpress feed (https://wordpress.org/?v=4.9.8) from: https://www.floridatrail.org/feed/

I'm manually replacing them on my app right now, but wanted to check if anybody knew where this issue was coming from.

Thanks 😊

codingmanu commented 5 years ago

Added spaces before the semicolons so GitHub wouldn't show them as the appropriate symbols.

nmdias commented 5 years ago

Hi, @codingmanu.

Is this still an issue? From what I can tell, the feed is showing HTML entities, as it might be trying to avoid special characters. As such, they must be manually converted back after parsing.

Thanks