http://qs321.pair.com?node_id=427232


in reply to Grepping out strings

$_ =~ /(http:\/\/[\w\.]+)/g;

seems to work OK for URLs starting http://, but that doesn't match www.mysite2.com as that doesn't have a http prefix in your example string.

VGhpcyBtZXNzYWdlIGludGVudGlvbmFsbHkgcG9pbnRsZXNz