I got some xml text line break issues in my latest project. The texts look good viewing them locally, but when uploading the project to the customer server I get a lot of extra line breaks. I am not really sure why this problem occurs but I guess it has to do with the server platform. I tried to save the xml with a different encoding but with no luck so I wrote this simple method. It works. 

public function fixLineBreakIssues(value : String) : String
{
    return value.split("\r").join("");
}
 
// usage
txtField.htmlText = fixLineBreakIssues(xmlText);

Post to Twitter

Related posts:

  1. Making large numbers look good
  2. Disable Mouse Scroll Wheel on textfields
  3. Merging XML files
  4. Breaking the conditional statement
  5. How to use Motor2 0.9 in Flash player 9