Annotation of embedaddon/php/ext/standard/tests/strings/add-and-stripslashes.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: addslashes() and stripslashes() functions, normal and sybase-style
        !             3: --FILE--
        !             4: <?php
        !             5: 
        !             6: $input = '';
        !             7: for($i=0; $i<512; $i++) {
        !             8:        $input .= chr($i%256);
        !             9: }
        !            10: 
        !            11: echo "Normal: ";
        !            12: ini_set('magic_quotes_sybase', 0);
        !            13: if($input === stripslashes(addslashes($input))) {
        !            14:        echo "OK\n";
        !            15: } else {
        !            16:        echo "FAILED\n";
        !            17: }
        !            18: 
        !            19: echo "Sybase: ";
        !            20: ini_set('magic_quotes_sybase', 1);
        !            21: if($input === stripslashes(addslashes($input))) {
        !            22:        echo "OK\n";
        !            23: } else {
        !            24:        echo "FAILED\n";
        !            25: }
        !            26: 
        !            27: ?>
        !            28: --EXPECT--
        !            29: Normal: OK
        !            30: Sybase: OK

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>