cjkenworthy
Programmer
I want to check if a user has put in a " anywhere in a set of text fields. How can I check for the " :
var invalid = """;
//I want invalid to be set to "
if (document.callback.txtnotes.value.indexOf(invalid) > -1) {
alert("Invalid character!"
;
return false;
}
This won't work! as it thinks that the " is part of the declaration.
var invalid = """;
//I want invalid to be set to "
if (document.callback.txtnotes.value.indexOf(invalid) > -1) {
alert("Invalid character!"
return false;
}
This won't work! as it thinks that the " is part of the declaration.