is it possible to insert a variable into a regular expression string? for example, something like this:
reg = /name="val"+i+"" value="[\w]+/gi
where i is the variable (an interger, let's say). then this should work for val0, val1, val2, etc.
Well, at least that's what I want. Please help!