/php-src/ext/standard/tests/strings/ |
H A D | strrchr_variation2.phpt | 5 /* Test strrchr() function by passing various single quoted strings to 'haystack' & 'needle' */ 9 $needle = array( 64 42, //needle as int(ASCII value of '*') 65 $haystack //haystack as needle 68 /* loop through to get the position of the needle in haystack string */ 70 for($index=0; $index<count($needle); $index++) { 72 var_dump( strrchr($haystack, $needle[$index]) );
|
H A D | strrpos_variation8.phpt | 5 /* Test strrpos() function with strings containing multiple occurrences of 'needle' in the 'haystac… 11 $needle = "aba"; 13 /* loop through to consider various offsets in getting the position of the needle in haystack strin… 17 var_dump( strrpos($haystack, $needle, $offset) );
|
H A D | strrchr_variation1.phpt | 6 /* Test strrchr() function by passing various double quoted strings for 'haystack' & 'needle' */ 10 $needle = array( 65 42, //needle as int(ASCII value of "*") 66 $haystack //haystack as needle 69 /* loop through to get the position of the needle in haystack string */ 71 for($index=0; $index<count($needle); $index++) { 73 var_dump( strrchr($haystack, $needle[$index]) );
|
H A D | strstr.phpt | 24 /* needles in an array to get the string starts with needle, in $string */ 57 /* loop through to get the string starts with "needle" in $string */ 66 echo "-- Passing objects as string and needle --\n"; 79 class needle 85 $obj_needle = new needle; 120 $needle = 'world'; 123 var_dump( strstr("Hello, world", "$needle") ); // works 124 var_dump( strstr("Hello, world'S", "$needle'S") ); // works 128 var_dump( strstr("Hello, worldS", "${needle}S") ); // works 129 var_dump( strstr("Hello, worldS", "{$needle}S") ); // works [all …]
|
H A D | strpos.phpt | 60 /* loop through to get the "needle" position in $string */ 81 /* loop through to get the "needle" position in $string */ 94 echo "-- Passing objects as string and needle --\n"; 107 class needle 113 $obj_needle = new needle; 149 $needle = 'world'; 152 var_dump( strpos("Hello, world", "$needle") ); // works 153 var_dump( strpos("Hello, world'S", "$needle'S") ); // works 157 var_dump( strpos("Hello, worldS", "${needle}S") ); // works 158 var_dump( strpos("Hello, worldS", "{$needle}S") ); // works [all …]
|
H A D | strripos_basic2.phpt | 10 echo "\n-- regular string for haystack & needle, with various offsets --\n"; 16 echo "\n-- heredoc string for haystack & needle, with various offsets --\n"; 36 -- regular string for haystack & needle, with various offsets -- 42 -- heredoc string for haystack & needle, with various offsets --
|
H A D | strrpos_basic1.phpt | 11 //regular string for haystack & needle 17 //single char for needle 21 //heredoc string for haystack & needle
|
/php-src/ext/mbstring/tests/ |
H A D | mb_strrchr_variation6.phpt | 24 // needle should be found 26 // no needle should be found 31 // needle should be found 39 // no needle should be found
|
H A D | mb_strstr_variation6.phpt | 24 // needle should be found 26 // no needle should be found 31 // needle should be found 39 // no needle should be found
|
H A D | mb_substr_count_variation4.phpt | 2 Test mb_substr_count() function : variation - pass a $needle that overlaps in $haystack 8 * Pass mb_substr_count() a $needle that overlaps in $haystack and see whether 18 var_dump(mb_substr_count($string_ascii, 'abcabc')); //needle overlaps in haystack
|
H A D | mb_stristr_variation5.phpt | 23 echo "\n-- ASCII string: needle exists --\n"; 32 echo "\n-- Multibyte string: needle exists --\n"; 44 -- ASCII string: needle exists -- 52 -- Multibyte string: needle exists --
|
H A D | mb_strrichr_variation5.phpt | 23 echo "\n-- ASCII string: needle exists --\n"; 32 echo "\n-- Multibyte string: needle exists --\n"; 44 -- ASCII string: needle exists -- 52 -- Multibyte string: needle exists --
|
H A D | mb_stripos_error2.phpt | 13 $needle = 'world'; 18 var_dump( mb_stripos($haystack, $needle, $offset, $encoding) );
|
H A D | mb_strpos_error2.phpt | 13 $needle = 'world'; 18 var_dump( mb_strpos($haystack, $needle, $offset, $encoding) );
|
H A D | mb_strripos_error2.phpt | 13 $needle = 'world'; 18 var_dump( mb_strripos($haystack, $needle, $offset, $encoding) );
|
H A D | mb_stristr_error2.phpt | 12 $needle = 'world'; 17 var_dump( mb_stristr($haystack, $needle, $part, $encoding) );
|
H A D | mb_strrchr_error2.phpt | 12 $needle = 'world'; 17 var_dump( mb_strrchr($haystack, $needle, $part, $encoding) );
|
H A D | mb_strrichr_error2.phpt | 12 $needle = 'world'; 17 var_dump( mb_strrichr($haystack, $needle, $part, $encoding) );
|
/php-src/ext/phar/tests/ |
H A D | bug74991.phpt | 11 touch('path/needle.php'); 13 …o 4096 (MAXPATHLEN) into 'phar://..sample.phar/some:xx..xx:pat' so it will fail to find needle.php: 14 …H_SEPARATOR . PATH_SEPARATOR . PATH) + OVERFLOW) . PATH_SEPARATOR . PATH); require('needle.php');"; 21 unlink('path/needle.php');
|
/php-src/ext/iconv/tests/ |
H A D | iconv_strpos.phpt | 9 function foo($haystk, $needle, $offset, $to_charset = false, $from_charset = false) 15 var_dump(strpos($haystk, $needle, $offset)); 21 var_dump(iconv_strpos($haystk, $needle, $offset, $to_charset)); 23 var_dump(iconv_strpos($haystk, $needle, $offset));
|
H A D | iconv_strrpos.phpt | 14 function foo($haystk, $needle, $to_charset = false, $from_charset = false) 21 var_dump(iconv_strrpos($haystk, $needle, $to_charset)); 24 var_dump(iconv_strrpos($haystk, $needle));
|
/php-src/ext/standard/tests/filters/ |
H A D | filter_errors.inc | 3 function filter_errors_skipif($needle) { 9 if (fnmatch($filter, $needle)) return; 11 die("skip $needle not available");
|
/php-src/Zend/tests/ |
H A D | frameless_jmp_001.phpt | 6 function test($needle, $haystack) { 7 return in_array($needle, $haystack, true);
|
/php-src/ext/intl/grapheme/ |
H A D | grapheme_util.h | 26 zend_long grapheme_strrpos_ascii(char *haystack, size_t haystack_len, char *needle, size_t needle_l… 28 int32_t grapheme_strrpos_utf16(char *haystack, size_t haystack_len, char *needle, size_t needle_len… 29 int32_t grapheme_strpos_utf16(char *haystack, size_t haystack_len, char *needle, size_t needle_len,…
|
/php-src/ext/mbstring/ |
H A D | mbstring.stub.php | 91 function mb_strpos(string $haystack, string $needle, int $offset = 0, ?string $encoding = null): in… argument 93 function mb_strrpos(string $haystack, string $needle, int $offset = 0, ?string $encoding = null): i… argument 95 function mb_stripos(string $haystack, string $needle, int $offset = 0, ?string $encoding = null): i… argument 97 function mb_strripos(string $haystack, string $needle, int $offset = 0, ?string $encoding = null): … argument 100 function mb_strstr(string $haystack, string $needle, bool $before_needle = false, ?string $encoding… argument 103 function mb_strrchr(string $haystack, string $needle, bool $before_needle = false, ?string $encodin… argument 106 function mb_stristr(string $haystack, string $needle, bool $before_needle = false, ?string $encodin… argument 109 function mb_strrichr(string $haystack, string $needle, bool $before_needle = false, ?string $encodi… argument 111 function mb_substr_count(string $haystack, string $needle, ?string $encoding = null): int {} argument
|