I am trying to add very simple script to a text box to allow only numerical input like this:
<input type="text" onkeypress="if ((event.keyCode < 48) || (event.keyCode > 57)) event.returnValue = false;" size=3 name=quantityOrdered/>
However when I save the code to the database it returns like this:
<input type="text" onkeypress="if ((event.keyCode < 48) || (event.keyCode /> 57)) event.returnValue = false;" size=3 name=quantityOrdered/>
As you can see a "/" is added before the "> 57" and breaks the script.... I am starting to get pretty annoyed now by this component... Please answer why this happens!