Searched refs:uasort (Results 1 – 25 of 30) sorted by relevance
12
2 Test uasort() function : error conditions 5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)10 echo "*** Testing uasort() : error conditions ***\n";37 echo "-- Testing uasort() function with Zero argument --\n";38 var_dump( uasort() );43 var_dump( uasort($array_arg, 'cmp', $extra_arg) );47 var_dump( uasort($array_arg) );51 var_dump( uasort($array_arg, 'non_existent') );55 var_dump( uasort($array_arg, 'non_existent', $extra_arg) );60 *** Testing uasort() : error conditions ***[all …]
2 Test uasort() function : usage variations - built-in function as 'cmp_function'5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)16 echo "*** Testing uasort() : built in function as 'cmp_function' ***\n";23 echo "-- Testing uasort() with built-in 'cmp_function': strcasecmp() --\n";27 echo "-- Testing uasort() with built-in 'cmp_function': strcmp() --\n";28 var_dump( uasort($array_arg, 'strcmp') ); // expecting: bool(true)41 *** Testing uasort() : built in function as 'cmp_function' ***42 -- Testing uasort() with built-in 'cmp_function': strcasecmp() --56 -- Testing uasort() with built-in 'cmp_function': strcmp() --70 -- Testing uasort() with language construct as 'cmp_function' --[all …]
2 Test uasort() function : usage variations - unexpected values for 'array_arg' argument5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)14 echo "*** Testing uasort() : unexpected values for 'array_arg' ***\n";91 var_dump( uasort($input_values[$count], 'cmp_function') );99 *** Testing uasort() : unexpected values for 'array_arg' ***118 Warning: uasort() expects parameter 1 to be array, double given in %s on line %d122 Warning: uasort() expects parameter 1 to be array, double given in %s on line %d138 Warning: uasort() expects parameter 1 to be array, null given in %s on line %d142 Warning: uasort() expects parameter 1 to be array, null given in %s on line %d182 Warning: uasort() expects parameter 1 to be array, null given in %s on line %d[all …]
2 Test uasort() function : usage variations - unexpected values for 'cmp_function' argument5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)11 * Testing uasort() function with different scalar and nonscalar values in place of 'cmp_function'14 echo "*** Testing uasort() : Unexpected values in place of comparison function ***\n";91 var_dump( uasort($array_arg, $cmp_values[$count]) );99 *** Testing uasort() : Unexpected values in place of comparison function ***102 Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on lin…106 Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on lin…110 Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on lin…114 Warning: uasort() expects parameter 2 to be a valid callback, no array or string given in %s on lin…[all …]
2 Test uasort() function : object functionality - sort diff. objects 19 echo "*** Testing uasort() : object functionality ***\n";94 var_dump( uasort($array_arg, 'cmp_function') );98 echo "-- Testing uasort() with EmptyClass objects --\n";105 var_dump( uasort($array_arg, 'cmp_function') );109 echo "-- Testing uasort() with ChildClass objects --\n";116 var_dump( uasort($array_arg, 'cmp_function') );122 *** Testing uasort() : object functionality ***123 -- Testing uasort() with StaticClass objects --139 -- Testing uasort() with EmptyClass objects --[all …]
2 Test uasort() function : usage variations - 'cmp_function' with reference argument 5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)10 /* Testing uasort() functionality with comparison function having arguments as reference13 echo "*** Testing uasort() : 'cmp_function' with reference arguments ***\n";38 var_dump( uasort($int_values, 'cmp') );44 var_dump( uasort($string_values, 'cmp') );50 *** Testing uasort() : 'cmp_function' with reference arguments ***
2 Test uasort() function : usage variations - sort different numeric values5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)36 echo "*** Testing uasort() : different numeric arrays as 'array_arg' ***\n";41 var_dump( uasort($int_values, 'cmp_function') ); // expecting: bool(true)47 var_dump( uasort($octal_values, 'cmp_function') ); // expecting: bool(true)53 var_dump( uasort($hex_values, 'cmp_function') ); // expecting: bool(true)59 var_dump( uasort($float_values, 'cmp_function') ); // expecting: bool(true)65 var_dump( uasort($empty_array, 'cmp_function') ); // expecting: bool(true)71 *** Testing uasort() : different numeric arrays as 'array_arg' ***
2 Test uasort() function : basic functionality - duplicate values5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)10 echo "*** Testing uasort() : basic functionality with duplicate values ***\n";35 var_dump( uasort($int_values1, 'cmp') );41 var_dump( uasort($int_values2, 'cmp') );47 var_dump( uasort($int_values3, 'cmp') );53 *** Testing uasort() : basic functionality with duplicate values ***
2 Test uasort() function : usage variations - different associative arrays5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)10 /* Testing uasort() with different associative arrays having keys as14 echo "*** Testing uasort() : sorting different associative arrays ***\n";39 var_dump( uasort($array_arg, 'cmp') );45 var_dump( uasort($array_arg, 'cmp') );51 *** Testing uasort() : sorting different associative arrays ***
2 Test uasort() function : basic functionality 5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)10 echo "*** Testing uasort() : basic functionality ***\n";35 var_dump( uasort($int_values, 'cmp') );41 var_dump( uasort($string_values, 'cmp') );47 var_dump( uasort($numeric_key_arg, 'cmp') );53 var_dump( uasort($string_key_arg, 'cmp') );59 *** Testing uasort() : basic functionality ***
2 Test uasort() function : usage variations - sort array with reference variables5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)11 * Testing uasort() with 'array_arg' containing different reference variables35 echo "*** Testing uasort() : 'array_arg' with elements as reference ***\n";53 var_dump( uasort($array_arg, 'cmp_function') ); // expecting: bool(true)59 *** Testing uasort() : 'array_arg' with elements as reference ***
2 Test uasort() function : usage variations - anonymous function as 'cmp_function'5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)16 echo "*** Testing uasort() : anonymous function as 'cmp_function' ***\n";22 var_dump( uasort($array_arg, create_function('$value1, $value2',$cmp_function) ) );27 var_dump( uasort($array_arg, create_function('&$value1, &$value2', $cmp_function) ) );33 *** Testing uasort() : anonymous function as 'cmp_function' ***
2 Test uasort() function : usage variations - sort array with all posible keys5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)11 * Testing uasort() with 'array_arg' having different keys14 echo "*** Testing uasort() : Sorting array with all possible keys ***\n";91 var_dump( uasort($array_arg, 'cmp_function') );92 echo "-- Sorted array after uasort() function call --\n";98 *** Testing uasort() : Sorting array with all possible keys ***100 -- Sorted array after uasort() function call --
2 Test uasort() function : usage variations - sort array having subarrays 5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)11 * Testing uasort() with 'array_arg' having different subarrays as array elements35 echo "*** Testing uasort() : sorting array having different subarrays ***\n";49 var_dump( uasort($temp_array, 'cmp_function') ); // expecting: bool(true)54 *** Testing uasort() : sorting array having different subarrays ***
2 Test uasort() function : usage variations - sort diff. strings 5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)54 echo "*** Testing uasort() : different string arrays as 'array_arg' ***\n";62 var_dump( uasort($single_quoted_values, 'cmp_function') ); // expecting: bool(true)71 var_dump( uasort($double_quoted_values, 'cmp_function') ); // expecting: bool(true)77 var_dump( uasort($heredoc_values, 'cmp_function') ); // expecting: bool(true)83 *** Testing uasort() : different string arrays as 'array_arg' ***
2 Test usort, uksort and uasort17 echo " -- Testing uasort() -- \n";18 uasort ($data, 'cmp');31 -- Testing uasort() --
2 Test uasort() function : object functionality 5 /* Prototype : bool uasort(array $array_arg, string $cmp_function)11 * Testing uasort() function with the array of objects15 echo "*** Testing uasort() : object functionality ***\n";81 var_dump( uasort($array_arg, 'simple_cmp') );90 var_dump( uasort($array_arg, 'multiple_cmp') );96 *** Testing uasort() : object functionality ***
2 Bug #50006 (Segfault caused by uksort()) - uasort variant11 uasort($data, 'magic_sort_cmp');
65 // Testing uasort with StaticClass objects as elements of 'array_arg'76 // Testing uasort with EmptyClass objects as elements of 'array_arg'87 // Testing uasort with ChildClass objects as elements of 'array_arg'
16 uasort($a, "cmp");
15 uasort($p1, 'a');
2 SPL: Test ArrayObject::uasort() function : basic functionality 5 /* Prototype : int ArrayObject::uasort(callback cmp_function)6 * Description: proto int ArrayIterator::uasort(callback cmp_function)12 echo "*** Testing ArrayObject::uasort() : basic functionality ***\n";27 $ao->uasort('cmp');32 *** Testing ArrayObject::uasort() : basic functionality ***
2 Test ArrayObject::uasort() function : wrong arg count 5 /* Prototype : int ArrayObject::uasort(callback cmp_function)6 * Description: proto int ArrayIterator::uasort(callback cmp_function)15 $ao->uasort();21 $ao->uasort(1,2);
657 function uasort(mixed cmp_function) {/**/} function in ArrayObject778 function uasort(mixed cmp_function) {/**/} function in ArrayIterator
39 PHP_FUNCTION(uasort);
Completed in 24 milliseconds