• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: HTML-encoded characters mucking up my NSStrings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: HTML-encoded characters mucking up my NSStrings


  • Subject: Re: HTML-encoded characters mucking up my NSStrings
  • From: Dustin Voss <email@hidden>
  • Date: Tue, 10 Feb 2004 15:22:23 -0800

On 9 Feb, 2004, at 9:32 PM, Tom Burns wrote:

What is the best way to replace HTML character codes (e.g. &#233, &#29; etc.) with their human-readable counterparts in an NSString?

CFStringRef unescapedCF = CFXMLCreateStringByUnescapingEntities (NULL, (CFStringRef) htmlString, NULL);
NSString *unescaped = [NSString stringWithString: (NSString *) unescapedCF];
CFRelease (unescapedCF);
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
  • Follow-Ups:
    • Re: HTML-encoded characters mucking up my NSStrings
      • From: Kyle Moffett <email@hidden>
References: 
 >HTML-encoded characters mucking up my NSStrings (From: Tom Burns <email@hidden>)

  • Prev by Date: Re: Where's the journal file on a journalled drive?
  • Next by Date: Re: Sneaky Key-Value Observing
  • Previous by thread: HTML-encoded characters mucking up my NSStrings
  • Next by thread: Re: HTML-encoded characters mucking up my NSStrings
  • Index(es):
    • Date
    • Thread