I have got the following regular expression working just fine in Rad Software Regular Expression designer.
param\s+name\s*=\s*"movie"\s+value=\s*"(?<target>.*?)"
And now I am wondering, how to get this to work in JavaScript. It keeps on complaining about the "target" part. I am trying to validate and get the url from the youtube embed code.
<object width="640" height="385"><param name="movie" value="http://www.youtube.com/v/ueZP6ifzqMY&hl=sv_SE&fs=1&rel=0"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/ueZP6ifzqMY&hl=sv_SE&fs=1&rel=0" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="640" height="385"></embed></object>
How the heck do I get this regex to work with my javascript?