- or download this
$str =~ s/http:\/\///g;
...
$str =~ s|http://||g;
$str =~ s#http://##g;
$str =~ s!http://!!g;
- or download this
$str =~ s!(/\*[^/]+\*/)!>>>> \1 <<<<!g; # /* comments */
$str =~ s!(\s//[^/\n]+)!>>>> \1 <<<<!g; # // comments
print $str;
- or download this
$str =~ s!(fancy re here)! print "$1\n"; "" !ge;