Regex to extract link
- by Derin
Hi,
I'm looking for a regex to extract links from a url. The url would be as below:
/redirecturl?u=http://www.abc.com/&tkn=Ue4uhv&ui=fWrQfyg46CADA&scr=SSTYQFjAA&mk=4D6GHGLfbQwETR
I need to extract the link http://www.abc.com from the above url.
I tried the regex:
redirecturl\\?u=(?<link>[^\"]+)&
This works, but the problem is that it does not truncate all the characters after the first occurrence of &.
It would be great if you could modify the regex so that I just get the link.
Thanks in advance.