Menu
I don’t know how to mix ‘s’ with regular literals.
What I would like to do is to be flexible on how many spaces there are after “My Foo”.
The first code works and testarray returns with something.
[CODE]
var test=”My Foo <span class=”subCounts”>((.*?))</span>”;
var testarray=document.body.innerHTML.match(new RegExp(test,’g’));
The second code doesn’t work and testarray returns null.
[CODE]
var test=”My Foos*<span class=”subCounts”>((.*?))</span>”;
var testarray=document.body.innerHTML.match(new RegExp(test,’g’));
So it tells me that I dunno how to use s*