c# - Extract Url from Javascript in -
i new in regex can please in writing regex in c# extract url text below?
example 1
x+=1; top.location.href = "http://www.keenthemes.com/preview/index.php?theme=metronic";
example 2
alert("are sure"); top.location.href = 'http://www.keenthemes.com/preview/index.php?theme=metronic';
if url starts http://
, 1 should it:
["'](http.*)["']
the url stored in second group (groups[1].value
) of match
object
Comments
Post a Comment