-4
rated 0 times
[
1]
[
5]
/ answers: 1 / hits: 76940
/ 11 Years ago, tue, april 16, 2013, 12:00:00
Seems pretty simple, but cannot figure out why this javascript code isn't working returning false, when expecting true) - I'm guessing it has got to do something with the escape characters? Could someone please help me write a JS block that will return true if whitespace present?
var inValid = new RegExp([s]);
var value = test space;
var k = inValid.test(value);
alert(k);
More From » regex