Forums: Flash:

 

stripping carriage returns out of a string

first
 

ernieweaselfat stripping carriage returns out of a string

Is it possible?

We are getting crap data from another source that is adding carriage returns. Is there a way to strip them out in actionscript?

Please help, I am in the office at 9 and we can't figure this simple stupid thing out.

Thanks!

 

Hideaway

someString.split("\n").join("");

//EDIT someString.split("\n").join("").split("\r").join("");

Might wanna strip out the "\r", too

I love boots. It's like midgets hugging my calves...
quote
 

ernieweaselfat

god, hideaway, that really helped me out. My brain was not working!

 
first
 

Forums: Flash: stripping carriage returns out of a string

 
New Post
 
You must be logged in to post