Linked Questions

12 questions linked to/from Encode NSString for XML/HTML
1324 votes
13 answers
1.8m views

I often find this strange CDATA tag in XML files: <![CDATA[some stuff]]> I have observed that this CDATA tag always comes at the beginning, and then followed by some stuff. But sometimes it is ...
600 votes
24 answers
545k views

I am looking for a way to replace characters in a Swift String. In this example String: "This is my string" I would like to replace the spaces, " ", with "+" to end up ...
75 votes
14 answers
98k views

Wondering if there is an easy way to do a simple HTML escape/unescape in Objective C. What I want is something like this psuedo code: NSString *string = @"&lt;span&gt;Foo&lt;/span&gt;...
3 votes
3 answers
576 views

I was trying to figure out why UIActivityViewController sent a slightly converted string to share for Mail and WeChat. This is my code: let activityViewController = UIActivityViewController(...
2 votes
3 answers
3k views

I have a list of several locations, some of them containing the letters æ, Æ, ø, Ø, å and Å. From the webservice I'm using, the letters comes out as "&oslash ;" "&Aring ;" etc. When I ...
2 votes
2 answers
773 views

My xml consist of words in few different language, Latin words etc. am able to parse these Latin characters and all except the fact that I am not able parse only "&" This is what I am ...
1 vote
0 answers
1k views

I have an rss feed that i am taking the description from using nsxmlparser. This is then output onto a tableview however it is html. is there a way to html encode a string in objective c on the iphone?...
1 vote
1 answer
1k views

I want to convert a NSString variable containing xml codes into xml format. My xml request is: <?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap....
0 votes
3 answers
826 views

I have an NSString that has the following value: "What#39;s up fellas!" Is there a simple way to turn HTML char codes like #39; (equivalent to ') into an apostrophe etc?
0 votes
1 answer
773 views

I have an iPhone app that will let users email some pre-determined text as HTML. I'm having a problem in that if the text contains special characters within the text (e.g., ampersand &,>, <)...
0 votes
2 answers
667 views

I have a textview which can take any input and I need to parse the quotes and double quotes as &apos; and &quot; respectively. So if I input a text in my text view like "Just testin'g quotes" ...
0 votes
0 answers
86 views

I am requesting to a SOAP server, everything is just fine but I have a small issue. When users type non-English characters like Chinese, Japanese or Vietnamese, I need to encode it. I have followed ...