Home
last modified time | relevance | path

Searched refs:array_filter (Results 1 – 24 of 24) sorted by relevance

/PHP-8.0/ext/standard/tests/array/
H A Darray_filter_variation10.phpt2 Test array_filter() function : usage variations - using the array keys inside 'callback'
9 echo "*** Testing array_filter() : usage variations - using array keys in 'callback' ***\n";
19 var_dump( array_filter($input, 'dump', true) );
28 var_dump( array_filter($input, 'dump2', true) );
33 var_dump( array_filter($small, 'dump', false) );
38 echo "*** Testing array_filter() with various use types ***\n";
42 var_dump(array_filter($mixed, 'is_numeric', ARRAY_FILTER_USE_KEY));
44 var_dump(array_filter($mixed, 'is_numeric', 0));
47 var_dump(array_filter($mixed, 'is_numeric', ARRAY_FILTER_USE_BOTH));
55 *** Testing array_filter() : usage variations - using array keys in 'callback' ***
[all …]
H A Darray_filter.phpt2 basic array_filter test
20 var_dump(array_filter($array1, "odd"));
21 var_dump(array_filter($array2, "odd"));
22 var_dump(array_filter($array3, "odd"));
24 var_dump(array_filter($array1, "even"));
25 var_dump(array_filter($array2, "even"));
26 var_dump(array_filter($array3, "even"));
28 var_dump(array_filter(array()));
H A Darray_filter_variation9.phpt2 Test array_filter() function : usage variations - built-in functions as 'callback' argument
9 echo "*** Testing array_filter() : usage variations - built-in functions as 'callback' argument ***…
14 var_dump( array_filter($input, 'is_int') );
17 var_dump( array_filter($input, 'chr') );
21 var_dump( array_filter($input, 'echo') );
28 var_dump( array_filter($input, 'exit') );
36 *** Testing array_filter() : usage variations - built-in functions as 'callback' argument ***
67 array_filter(): Argument #2 ($callback) must be a valid callback, function "echo" not found or inva…
68 array_filter(): Argument #2 ($callback) must be a valid callback, function "exit" not found or inva…
H A Darray_filter_basic.phpt2 Test array_filter() function : basic functionality
5 echo "*** Testing array_filter() : basic functionality ***\n";
17 var_dump( array_filter($input,"even") );
20 var_dump( array_filter($input) );
22 var_dump( array_filter($input, null) );
27 *** Testing array_filter() : basic functionality ***
H A Darray_filter_variation5.phpt2 Test array_filter() function : usage variations - 'input' argument with different false entries
6 * With default callback function argument, array_filter() removes elements which are interpreted as…
21 echo "*** Testing array_filter() : usage variations - different false elements in 'input' ***\n";
52 var_dump( array_filter($input) );
55 var_dump( array_filter($input, 'always_true') );
58 var_dump( array_filter($input, 'always_false') );
63 *** Testing array_filter() : usage variations - different false elements in 'input' ***
H A Darray_filter_variation8.phpt2 Test array_filter() function : usage variations - Callback function with different return values
6 * callback functions are expected to return bool value for array_filter()
10 echo "*** Testing array_filter() : usage variations - callback function with different return value…
19 var_dump( array_filter($input, 'callback1') );
27 var_dump( array_filter($input, 'callback2') );
35 var_dump( array_filter($input, 'callback3') );
43 var_dump( array_filter($input, 'callback4') );
51 var_dump( array_filter($input, 'callback5') );
56 *** Testing array_filter() : usage variations - callback function with different return values***
H A Darray_filter_variation4.phpt2 Test array_filter() function : usage variations - Different types of 'callback' function
6 * Passing different types of callback functions to array_filter()
13 echo "*** Testing array_filter() : usage variation - different 'callback' functions***\n";
23 var_dump( array_filter($input, "callback1") );
30 var_dump( array_filter($input, "callback2") );
36 var_dump( array_filter($input, "callback3") );
49 var_dump( array_filter($input, "callback4") );
54 *** Testing array_filter() : usage variation - different 'callback' functions***
H A Darray_filter_variation6.phpt2 Test array_filter() function : usage variations - 'input' array containing references
9 echo "*** Testing array_filter() : usage variations - 'input' containing references ***\n";
27 var_dump( array_filter($input, 'callback') );
30 var_dump( array_filter($input) );
35 *** Testing array_filter() : usage variations - 'input' containing references ***
H A Darray_filter_variation7.phpt2 Test array_filter() function : usage variations - anonymous callback functions
9 echo "*** Testing array_filter() : usage variations - Anonymous callback functions ***\n";
15 var_dump( array_filter($input, function($input) { return ($input > 1); }) );
19 var_dump( array_filter($input, function() { return true; }) );
23 var_dump( array_filter($input, function($input) { }) );
28 *** Testing array_filter() : usage variations - Anonymous callback functions ***
H A Darray_filter_object.phpt2 Test array_filter() function : object functionality
6 * it to array_filter() to test object functionality
13 echo "*** Testing array_filter() : object functionality ***\n";
85 var_dump( array_filter($input) );
88 var_dump( array_filter($input, "always_true") );
91 var_dump( array_filter($input, "always_false") );
96 *** Testing array_filter() : object functionality ***
H A Darray_filter_variation3.phpt2 Test array_filter() function : usage variations - Different types of array for 'input' argument
20 echo "*** Testing array_filter() : usage variations - different types of array for 'input' argument…
39 var_dump( array_filter($input_values[$count]) );
40 var_dump( array_filter($input_values[$count], 'always_true') );
41 var_dump( array_filter($input_values[$count], 'always_false') );
47 *** Testing array_filter() : usage variations - different types of array for 'input' argument***
H A Dbug69299.phpt2 Bug #69299 (Regression in array_filter's $flag argument in PHP 7)
6 $filtered = array_filter($toFilter, function ($value, $key) {
H A Dbug34227.phpt2 Bug #34277 (array_filter() crashes with references and objects)
73 $ret = array_filter(array(0), 'f');
H A Dbug74345.phpt26 array_filter([], $cb);
/PHP-8.0/sapi/cli/tests/
H A Dbug64878.phpt14 echo count(array_filter($headers, function ($value) {
/PHP-8.0/scripts/dev/
H A Dfind_tested.php212 $functions = array_filter($tokens, 'filter_functions');
/PHP-8.0/ext/standard/tests/strings/
H A Dsetlocale_variation2.phpt41 return array_filter($system_locales, 'good_locale');
/PHP-8.0/build/
H A Dgen_stub.php288 return new Type(array_filter($this->types, function(SimpleType $type) {
/PHP-8.0/ext/standard/
H A Dbasic_functions.stub.php234 function array_filter(array $array, ?callable $callback = null, int $mode = 0): array {} function
H A Dbasic_functions_arginfo.h2307 ZEND_FUNCTION(array_filter);
2932 ZEND_FE(array_filter, arginfo_array_filter)
H A Darray.c5899 PHP_FUNCTION(array_filter) argument
/PHP-8.0/sapi/fpm/tests/
H A Dtester.inc609 return array_filter($params, function ($value) {
/PHP-8.0/
H A Drun-tests.php1326 $test_files = array_filter($test_files, function($test) {
H A DUPGRADING615 parameters is used. Examples include array_filter() and array_reduce().

Completed in 81 milliseconds