I\'ve come across an error in my web app that I\'m not sure how to fix.
Text boxes are sending me the long dash as part of their content (you know, the special long dash
This code might help:
text = text.replace(/\u2013|\u2014/g, "-");
It replaces all – (–) and — (—) symbols with simple dashes (-).
–
—
DEMO: http://jsfiddle.net/F953H/