Might be a little sloppy, and I'm sure there is a more effecient Regex operation to do this, but this works.
myURL = 'http://foo/bar.html' destURL = 'leetPage.html' myURL.sub( /\bfoo\/.*/, 'foo/' + destURL ) Basically the Regex inside the string sub() function looks for the first instnace of `foo/` and replaces it with `foo/` + your desired web page string. Hope this helps, Nathan Christie --------------------------------------------------------------------- Posted via Jive Forums http://forums.openqa.org/thread.jspa?threadID=6091&messageID=17062#17062 _______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
