/ Published in: ActionScript 3
All credit for this goes to iheartactionscript.com I'm just copying it here so I won't have to remember where I found it
Expand |
Embed | Plain Text
var theContent:String = “I hate when content has words like, ‘damn’ in it” theContent = theContent.split(“damn”).join(“darn”); trace(theContent); // outputs: I hate when content has words like, ‘darn’ in it
Comments
Subscribe to comments
You need to login to post a comment.

Why not to use replace method? theContent.replace("damn", "darn");