I am trying to use an HTML form and javascript (i mention this, because some advanced features of regex processing are not available when using it on javascript) to acomplish the following:
feed the form some text, and use a regex to look into it and "capture" certain parts of it to be used as variables...
i.e. the text is:
"abcde email: [email protected] email: [email protected] sdfsdaf..."
... now, my problem is that I cannot think of an elegant way of capturing both emails as the variables e1 and e2, for example.
the regex I have so far is something like this: /email: (\b\w+\b)/g but for some reason, this is not giving back the 2 matches... it only gives back [email protected] ><
sugestions?