Posted By

gromitski on 02/28/11


Tagged

regex actionscript


Versions (?)

Replace white space in a string with "-"


 / Published in: ActionScript 3
 

URL: http://gromitski.com/blog/replacing-white-space-in-a-string/

Replace "-" with anything you want to. Useful for amending URLs.

  1. yourString = yourString.replace(/\s+/g, '-');

Report this snippet  

You need to login to post a comment.