Help for this page

Select Code to Download


  1. or download this
    my $str="McGlaughlin http://www.karayiannis.com and http://www.samy.co
    +m";
    $str =~ s/\b((?:http\:\/\/)|(?:www\.))([^ ]+)/<a href=\"$&\">$&<\/a>/s
    +gi;
    print $str;
    __END__
    McGlaughlin <a href="http://www.karayiannis.com">http://www.karayianni
    +s.com</a> and <a href="http://www.samy.com">http://www.samy.com</a>