I’m using RSS data in a mobile app. Some of the text in the RSS is coming back using ASCII codes. It seems to render normally sometimes, but not others. Specifically, apostrophes, greater thans, and quotes are coming through as ASCII codes, and only in an IconItemRenderer for which I am using a messageFunction:
protected function myMessageFunction(item:Object):String
{
return String((item as XML).title );
}
// text displayed in my IconItemRenderer's message field contains & #39; > and "
All the information I’ve found about converting ASCII codes pertains to feeding in one ASCII code and converting that one character. I want a method into which I can feed an entire string containing zero or more ASCII characters, and have all those ASCII codes converted into human-readable characters.
unescape() doesn’t do it. fromCharCode() doesn’t do it when I use the entire string as the argument. Do I need to use a Regular Expression to find each ASCII code in the String and convert each one individually? Seems this should be a more automatic process. Am I missing something stupid?
Thanks.