Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js replace space

// replaces space with '_'
str = str.replace(/ /g, "_");
// or
str = str.split(' ').join('_');
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #js #replace #space
ADD COMMENT
Topic
Name
8+1 =