Iam using one Jquery Library which takes the Regular expression in json format in on file and tries to validate that from file
"Studentnumber":{
regex: "/^[-/@#&$*\w\s]+$/",
alertText: "* Invalid Student Number"
}, // ...
I can use this in my text box field as follows
<input type="text" class="validate[required,custom[Studentnumber]] Textbox">
Earlier I used to have JavaScript Regular Expression for the field such as follows
<input type="text" validate="regex" regex='^[-/@#&$*\w\s]+$' name="sno" id="sno">
When I use the same regular expression that is used in the JavaScript for jquery. It is not validating as the same in JavaScript and giving inappropriate results. What is the Difference between the two?