I would like to define a regex in Javascript that allows to verify an other input regex
Any helps ar welcome
thanks.
A simpler way:
try
{
new RegExp(inputRegex);
}
catch (e)
{
alert("Invalid regex");
}
I would like to define a regex in Javascript that allows to verify an other input regex
Any helps ar welcome
thanks.
A simpler way:
try
{
new RegExp(inputRegex);
}
catch (e)
{
alert("Invalid regex");
}
精彩评论