Im having a little problem with a regular expressions. Here is the code
I cant figure out why this doesn't work, well to my understanding this should work...Code:
var pattern = new RegExp("(^|\s)match_me(\s|$)");
Iv also tried
And it also doesn't work.Code:
var pattern = new RegExp("(^|\s|\b)match_me(\b|\s|$)");
Can anyone help?
Thanks in advance :)