Home
last modified time | relevance | path

Searched refs:in_array (Results 1 – 25 of 101) sorted by relevance

12345

/PHP-5.3/ext/standard/tests/array/
H A Din_array_errors.phpt2 Test in_array() function : error conditions
6 * Prototype : bool in_array ( mixed $needle, array $haystack [, bool $strict] )
12 echo "\n*** Testing error conditions of in_array() ***\n";
14 var_dump( in_array() );
16 /* unexpected no.of arguments in in_array() */
18 var_dump( in_array(1, $var, 0, "test") );
19 var_dump( in_array("test") );
21 /* unexpected second argument in in_array() */
23 var_dump( in_array("test", $var) );
24 var_dump( in_array(1, 123) );
[all …]
H A Din_array_variation3.phpt14 /* checking for sub-arrays with in_array() */
15 echo "*** Testing sub-arrays with in_array() ***\n";
23 var_dump( in_array("four", $sub_array) );
25 var_dump( in_array(3, $sub_array[1]) );
26 var_dump( in_array(array('','i'), $sub_array) );
28 /* checking for objects in in_array() */
29 echo "\n*** Testing objects with in_array() ***\n";
39 var_dump( in_array("array_var", $in_array_obj) );
41 var_dump( in_array("foo", $in_array_obj) );
48 *** Testing sub-arrays with in_array() ***
[all …]
H A Din_array_variation4.phpt15 echo "*** Testing resource type with in_array() ***\n";
26 var_dump( in_array($file_handle, $resources, true) );
33 var_dump( in_array("Good", array(0,"hello")) );
38 var_dump( in_array(0, array("this")) );
40 var_dump( in_array(0, array("this")),TRUE );
43 var_dump( in_array("this", array(0)) );
45 var_dump( in_array("this", array(0), TRUE) );
48 var_dump( in_array(FALSE,
56 var_dump( in_array('123abc', array(123)) );
62 *** Testing resource type with in_array() ***
[all …]
H A Din_array_variation2.phpt2 Test in_array() function : usage variations - different haystack values
6 * Prototype : bool in_array ( mixed $needle, array $haystack [, bool $strict] )
12 /* Test in_array() with different possible haystack values */
14 echo "*** Testing in_array() with different haystack values ***\n";
35 $array_type on elements in $misc_array using in_array();
42 var_dump( in_array($type,$misc_array ) );
44 var_dump( in_array($type,$misc_array,true) );
46 var_dump( in_array($type,$misc_array,false) );
53 *** Testing in_array() with different haystack values ***
H A Darray_search.phpt2 Test array_search()/in_array()
11 var_dump(in_array(123, $arr2));
12 var_dump(in_array(123, $arr1));
14 var_dump(in_array('a', $arr1));
H A Din_array_variation1.phpt2 Test in_array() function : usage variations - different needdle values
6 * Prototype : bool in_array ( mixed $needle, array $haystack [, bool $strict] )
12 /* Test in_array() with different possible needle values */
14 echo "*** Testing in_array() with different needle values ***\n";
47 using in_array() */
53 var_dump(in_array($compare,$array));
55 var_dump(in_array($compare,$array,TRUE));
57 var_dump(in_array($compare,$array,FALSE));
65 *** Testing in_array() with different needle values ***
/PHP-5.3/ext/date/tests/
H A Dtimezones-list.phpt10 echo in_array( "Europe/Oslo", $a ) ? "found" : "notfound", "\n";
11 echo in_array( "Europe/Oslo", $b ) ? "found" : "notfound", "\n";
12 echo in_array( "Europe/Oslo", $c ) ? "found" : "notfound", "\n";
13 echo in_array( "Europe/Oslo", $d ) ? "found" : "notfound", "\n\n";
20 echo in_array( "UTC", $a ) ? "found" : "notfound", "\n";
21 echo in_array( "UTC", $b ) ? "found" : "notfound", "\n";
22 echo in_array( "UTC", $c ) ? "found" : "notfound", "\n";
23 echo in_array( "UTC", $d ) ? "found" : "notfound", "\n\n";
25 echo in_array( "US/Eastern", $a ) ? "found" : "notfound", "\n";
26 echo in_array( "US/Eastern", $b ) ? "found" : "notfound", "\n";
[all …]
H A Dtimezone_identifiers_list_basic1.phpt21 var_dump(in_array("Europe/London", $zones));
22 var_dump(in_array("America/New_York", $zones));
23 var_dump(in_array("UTC", $zones));
H A DDateTimeZone_listIdentifiers_basic1.phpt21 var_dump(in_array("Europe/London", $zones));
22 var_dump(in_array("America/New_York", $zones));
23 var_dump(in_array("UTC", $zones));
/PHP-5.3/ext/mbstring/tests/
H A Dmb_list_encodings.phpt7 var_dump(in_array("7bit", mb_list_encodings()));
8 var_dump(in_array("8bit", mb_list_encodings()));
9 var_dump(in_array("ASCII", mb_list_encodings()));
10 var_dump(in_array("non-existent", mb_list_encodings()));
/PHP-5.3/Zend/tests/
H A Dget_defined_functions_basic.phpt37 if (!in_array("cos", $internal) || !in_array("strlen", $internal)) {
47 if (count($user) == 2 && in_array("foo", $user) && in_array("helloworld", $user)) {
/PHP-5.3/win32/build/
H A Dmkdist.php73 $is_pecl = in_array($module, $pecl_targets);
88 if (((in_array($depbase, $sapi_targets) ||
89 in_array($depbase, $ext_targets) || in_array($depbase, $pecl_targets)) ||
94 if (in_array(basename($dep), $no_dist)) {
99 if (!in_array($dep, $pecl_dll_deps)) {
103 if (!in_array($dep, $extra_dll_deps)) {
285 if (in_array($modulename, $pecl_targets))
337 if (in_array($dll, $extra_dll_deps)) {
/PHP-5.3/ext/phar/tests/
H A Dphar_get_supported_signatures_002.phpt8 if (in_array("OpenSSL", $arr)) die("skip openssl support enabled");
9 if (!in_array('SHA-256', $arr)) die("skip hash extension loaded shared");
H A Dphar_get_supported_signatures_002a.phpt8 if (!in_array("OpenSSL", $arr)) die("skip openssl support required");
9 if (!in_array('SHA-256', $arr)) die("skip hash extension loaded shared");
H A Dtest_signaturealgos.phpt8 if (!in_array("OpenSSL", $arr)) die("skip openssl support required");
9 if (!in_array('SHA-256', $arr)) die("skip hash extension loaded shared");
/PHP-5.3/ext/dba/tests/
H A Dskipif.inc7 if (in_array('flatfile', $handlers)) {
17 if (!in_array($handler, dba_handlers())) {
/PHP-5.3/scripts/dev/generate-phpt/src/setup/
H A DgtCommandLineOptions.php56 if (!in_array($option, array_merge($this->shortOptions, $this->shortOptionsWithArgs)))
61 if (in_array($option, $this->shortOptions)) {
/PHP-5.3/ext/standard/tests/class_object/
H A Dget_declared_interfaces_variation1.phpt19 var_dump(in_array('AutoInterface', get_declared_interfaces()));
24 var_dump(in_array('AutoInterface', get_declared_interfaces()));
H A Dget_declared_classes_variation1.phpt19 var_dump(in_array('AutoLoaded', get_declared_classes()));
23 var_dump(in_array('AutoLoaded', get_declared_classes()));
H A Dget_declared_classes_basic_001.phpt26 var_dump(in_array('C', get_declared_classes()));
30 var_dump(in_array( 'I', get_declared_classes()));
H A Dget_declared_interfaces_basic_001.phpt26 var_dump(in_array('C', get_declared_interfaces()));
30 var_dump(in_array('I', get_declared_interfaces()));
/PHP-5.3/scripts/dev/generate-phpt/src/setup/preconditions/
H A DgtIsValidClass.php12 if( in_array( $className, get_declared_classes() ) ) {
H A DgtIsValidFunction.php13 if( in_array( $function, $functions['internal'] ) ) {
/PHP-5.3/ext/phar/phar/
H A Dphar.php19 if (!in_array('phar', stream_get_wrappers())) {
/PHP-5.3/ext/mcrypt/tests/
H A Dmcrypt_list_algorithms.phpt8 if (in_array($algo, array('rijndael-256', 'des', 'blowfish', 'twofish'))) {

Completed in 38 milliseconds

12345