Re: Converting NSString to valid HTML string

2008-08-21 Thread Nate Weaver
Those are for URL encoding; I think he wants HTML entities. I can't remember if there are Cocoa methods to do this, but you can use CFXMLCreateStringByEscapingEntities() (since NSString * and CFStringRef are toll-free bridged): NSString *input = @"2 < 4"; NSString *output = (NSString *)CF

Re: Converting NSString to valid HTML string

2008-08-21 Thread Randall Meadows
On Aug 21, 2008, at 12:16 PM, JanakiRam wrote: I'm developing an Cocoa client application.As part of application logic , i make the Webservice Call with XML data - which returns the XML file as response which contains the HTML code for the special characters. While sending the data i need t

Converting NSString to valid HTML string

2008-08-21 Thread JanakiRam
Hi All, I'm developing an Cocoa client application.As part of application logic , i make the Webservice Call with XML data - which returns the XML file as response which contains the HTML code for the special characters. While sending the data i need to convert the special characters such as &,' e