Lines Matching refs:rtrim
2 Test rtrim() function : error conditions
6 /* Prototype : string rtrim ( string $str [, string $charlist ] )
12 echo "*** Testing rtrim() : error conditions ***\n";
14 echo "\n-- Testing rtrim() function with no arguments --\n";
15 var_dump( rtrim() );
17 echo "\n-- Testing rtrim() function with more than expected no. of arguments --\n";
19 var_dump( rtrim("Hello World", "Heo", $extra_arg) );
23 echo "\n-- Test rtrim function with various invalid charlists\n";
24 var_dump(rtrim($hello, "..a"));
25 var_dump(rtrim($hello, "a.."));
26 var_dump(rtrim($hello, "z..a"));
27 var_dump(rtrim($hello, "a..b..c"));
32 *** Testing rtrim() : error conditions ***
34 -- Testing rtrim() function with no arguments --
36 Warning: rtrim() expects at least 1 parameter, 0 given in %s on line %d
39 -- Testing rtrim() function with more than expected no. of arguments --
41 Warning: rtrim() expects at most 2 parameters, 3 given in %s on line %d
44 -- Test rtrim function with various invalid charlists
46 Warning: rtrim(): Invalid '..'-range, no character to the left of '..' in %s on line %d
50 Warning: rtrim(): Invalid '..'-range, no character to the right of '..' in %s on line %d
54 Warning: rtrim(): Invalid '..'-range, '..'-range needs to be incrementing in %s on line %d
58 Warning: rtrim(): Invalid '..'-range in %s on line %d