Help for this page

Select Code to Download


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