/ Published in: JavaScript
"Text you want to make CamelCase" => "TextYouWantToMakeCamelCase"
Used this for making better addresses from blog-post titles.
Used this for making better addresses from blog-post titles.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
"Text you want to make CamelCase".replace(/ [^ ]+/g,function(match){ return match.substring(1,2).toUpperCase()+match.substring(2); });