Lines Matching refs:array_rand
2 Test array_rand() function : usage variation - invalid values for 'req_num' parameter
6 * Test behaviour of array_rand() function when associative array and
11 echo "*** Testing array_rand() : with invalid values for 'req_num' ***\n";
20 // Testing array_rand() function with various invalid 'req_num' values
23 var_dump( array_rand($input) ); // with default $num_req value
25 var_dump( array_rand($input, 1) ); // with valid $num_req value
30 var_dump( array_rand($input, 0) ); // with $num_req=0
37 var_dump( array_rand($input, -1) ); // with $num_req=-1
44 var_dump( array_rand($input, -2) ); // with $num_req=-2
51 var_dump( array_rand($input, 13) ); // with $num_req=13
58 *** Testing array_rand() : with invalid values for 'req_num' ***
67 array_rand(): Argument #2 ($num) must be between 1 and the number of elements in argument #1 ($arra…
70 array_rand(): Argument #2 ($num) must be between 1 and the number of elements in argument #1 ($arra…
73 array_rand(): Argument #2 ($num) must be between 1 and the number of elements in argument #1 ($arra…
76 array_rand(): Argument #2 ($num) must be between 1 and the number of elements in argument #1 ($arra…