open_in_new
content_copy
alert("this is a test".split(" ").join("-")); //or title.replace(/\s/g , "-");