Question : stripslashes in perl

In Perl, how can I perform the same action that stripslashes does in php?

Answer : stripslashes in perl

Shouldn't be too hard.  According to the php docs you just remove backslashes from \", \', and \\.

sub stripslashes() {

    $_ = shift();
    s/\\'/'/;
    s/\\"/"/;
    s/\\\\/\\/;

    return $_;

}
Random Solutions  
 
programming4us programming4us