I'm getting a web service response which contains strings like yesterday"&rsquo";s (without the quotes) and it also contains line jumps (\n). I've used (Convert HTML to Plain Text in Swift) to get the plain string but I loose the line jumps. Is there a way to decode that string and keep the line jumps?
Asked
Active
Viewed 492 times
1
-
1Does this help http://stackoverflow.com/a/30141700/1187415 ? – Martin R Jul 30 '15 at 19:35
-
Yeah, had to add "’" : "'", to XML predefined entities. So I'll guess I'll add more when they appear. – Marcos Griselli Jul 30 '15 at 19:44
-
I was too lazy to add all the > 250 HTML entities :) – Martin R Jul 30 '15 at 19:47