I have a string like this:
var str = \"I\'m a very^ we!rd* Str!ng.\";
What I would like to do is removing all special characters from the a
Assuming by "special" you mean non-word characters, then that is pretty easy.
str = str.replace(/[_\W]+/g, "-")