You might also consider using HTML entities for those, as you never know what the browser/user-agent has set for encoding...
On Mar 18, 2011, at 11:24 PM, Gary L. Wade wrote: > In that case, you should determine what encoding your web page is being > displayed in and convert your NSString to that encoding. If it's in UTF8, you > can use UTF8String; otherwise, consider dataUsingEncoding: or related > messages to see if that will do what you need. > > - Gary L. Wade (Sent from my iPad) > > On Mar 18, 2011, at 8:03 AM, "Heizer, Charles" <[email protected]> wrote: > >> I'm looking to clean up some system profiler data before sending it to a >> database to have it displayed on a web page. Wile I can insert the data in >> to the MySQL database just fine. The copyright and registered symbols do >> not display properly on a web page. I was just thinking to make life easy >> I could just remove them before posting to my database so that I don¹t >> have to deal with it on the web end. >> >> Charles >> >> >> >> >> >> >> On 3/17/11 12:12 PM, "Gary L. Wade" <[email protected]> wrote: >> >>> Is it possible you're assuming text being given to you is in ASCII format >>> but is actually in UTF-8 or some other encoding? Try looking at the text >>> you have in other encodings before trying to remove characters. >>> >>> On 03/17/2011 6:03 AM, "Heizer, Charles" <[email protected]> wrote: >>> >>>> Hello, >>>> I would like to know how to remove certain characters from a NSString. >>>> The >>>> characters are "©". I thought I could just use encodings and convert the >>>> string using NSASCIIStringEncoding but that did not work and I'm not sure >>>> what the car codes are for these as well. >>>> >>>> Thanks, >>>> Charles >>> >>> >>> _______________________________________________ >>> >>> Cocoa-dev mailing list ([email protected]) >>> >>> Please do not post admin requests or moderator comments to the list. >>> Contact the moderators at cocoa-dev-admins(at)lists.apple.com >>> >>> Help/Unsubscribe/Update your Subscription: >>> http://lists.apple.com/mailman/options/cocoa-dev/heizer1%40llnl.gov >>> >>> This email sent to [email protected] >> > _______________________________________________ > > Cocoa-dev mailing list ([email protected]) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/cocoa-dev/jjoyce%40apple.com > > This email sent to [email protected] _______________________________________________ Cocoa-dev mailing list ([email protected]) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [email protected]
