This was tricky. I format telephone numbers using
. This was fine except when being sumbited in a edit form. I needed to filter the spaces as part of an
isNumeric function. Filtering spaces was easy
strString = strString.replace(/ /g, ""); // remove spaces
but filtering took a while. Finally found the answer on the linked page
strString = strString.replace(/\xA0/g, ""); // remove non-break spaces ( )
The hex code for a rendered
is xA0 or 160 decimal