Sanal Rajan

Sanal Rajan

  • 1.5k
  • 174
  • 2.6k

Testing regular expression with single quotes giving error

Aug 21 2017 2:15 AM
var Reg1= /^(^[a-zA-Z0-9-.,#/()&/'';:~`@#$%^*_+= -]{2,50})*$/;
if (!Reg1.test(txtreg)) {
}
 
This regular cotains single quotes. How to check this regular expression? 

Answers (3)