Home
last modified time | relevance | path

Searched refs:strncasecmp (Results 1 – 25 of 79) sorted by relevance

1234

/PHP-8.0/ext/standard/tests/strings/
H A Dstrncasecmp_basic.phpt2 Test strncasecmp() function : basic functionality
5 echo "*** Testing strncasecmp() function: basic functionality ***\n";
7 echo "-- Testing strncasecmp() with single quoted string --\n";
8 var_dump( strncasecmp('Hello', 'Hello', 5) ); //expected: int(0)
9 var_dump( strncasecmp('Hello', 'Hi', 5) ); //expected: value < 0
12 echo "-- Testing strncasecmp() with double quoted string --\n";
17 echo "-- Testing strncasecmp() with here-doc string --\n";
21 var_dump( strncasecmp($str, "Hello", 5) ); //expected: int(0)
29 -- Testing strncasecmp\(\) with single quoted string --
33 -- Testing strncasecmp\(\) with double quoted string --
[all …]
H A Dstrncasecmp_error.phpt2 Test strncasecmp() function : error conditions
5 echo "*** Testing strncasecmp() function: error conditions ***\n";
9 echo "-- Testing strncasecmp() function with invalid argument --\n";
13 var_dump( strncasecmp($str1, $str2, $len) );
20 *** Testing strncasecmp() function: error conditions ***
21 -- Testing strncasecmp() function with invalid argument --
22 strncasecmp(): Argument #3 ($length) must be greater than or equal to 0
H A Dstrncasecmp_variation7.phpt2 Test strncasecmp() function : usage variations - binary safe
5 /* Test strncasecmp() function with null terminated strings and binary values passed to 'str1' & 's…
7 echo "*** Test strncasecmp() function: with null terminated strings and binary inputs ***\n";
13 var_dump( strncasecmp($str1, $str2, 12) );
14 var_dump( strncasecmp($str3, "Hello,world", 12) );
19 *** Test strncasecmp() function: with null terminated strings and binary inputs ***
H A Dbug36944.phpt2 Bug #36944 (strncmp & strncasecmp do not return false on negative string length)
15 var_dump(strncasecmp("test ", "E", -1));
19 var_dump(strncasecmp("test ", "E", 10));
20 var_dump(strncasecmp("test ", "E", 0));
27 strncasecmp(): Argument #3 ($length) must be greater than or equal to 0
H A Dstrncasecmp_variation3.phpt2 Test strncasecmp() function: usage variations - various lengths
5 /* Test strncasecmp() with various lengths */
7 echo "*** Test strncasecmp() function: with different lengths ***\n";
14 var_dump( strncasecmp($str1, $str2, $len) );
19 *** Test strncasecmp() function: with different lengths ***
H A Dstrncasecmp_variation8.phpt2 Test strncasecmp() function: usage variations - single quoted strings
5 /* Test strncasecmp() function with various single quoted strings for 'str1', 'str2' */
7 echo "*** Test strncasecmp() function: with single quoted strings ***\n";
19 … var_dump( strncasecmp( $strings[$index1], $strings[$index2], (strlen($strings[$index1]) + 1) ) );
26 \*\*\* Test strncasecmp\(\) function: with single quoted strings \*\*\*
H A Dstrncasecmp_variation1.phpt2 Test strncasecmp() function: usage variations - case-sensitivity
5 /* Test strncasecmp() function with upper-case and lower-case alphabets as inputs for 'str1' and 's…
7 echo "*** Test strncasecmp() function: with alphabets ***\n";
10 …var_dump( strncasecmp( chr($ASCII), chr($ASCII), 1 ) ); //comparing uppercase letter with corresp…
11 …var_dump( strncasecmp( chr($ASCII), chr($ASCII + 32), 1 ) ); //comparing uppercase letter with co…
16 …var_dump( strncasecmp( chr($ASCII), chr($ASCII), 1 ) ); //comparing lowercase letter with corresp…
17 …var_dump( strncasecmp( chr($ASCII), chr($ASCII - 32), 1 ) ); //comparing lowercase letter with co…
22 *** Test strncasecmp() function: with alphabets ***
H A Dstrncasecmp_variation2.phpt2 Test strncasecmp() function: usage variations - double quoted strings
5 /* Test strncasecmp() function with various double quoted strings for 'str1', 'str2' */
7 echo "*** Test strncasecmp() function: with double quoted strings ***\n";
20 … var_dump( strncasecmp( $strings[$index1], $strings[$index2], (strlen($strings[$index1]) + 1) ) );
27 \*\*\* Test strncasecmp\(\) function: with double quoted strings \*\*\*
H A Dstrncasecmp_variation9.phpt2 Test strncasecmp() function: usage variations - heredoc strings
5 /* Test strncasecmp() function with here-doc strings for 'str1', 'str2' */
7 echo "*** Test strncasecmp() function: with here-doc strings ***\n";
66 var_dump( strncasecmp( $strings[$index1], $strings[$index1], strlen($strings[$index1]) ) );
67 var_dump( strncasecmp( $strings[$index1], $strings[$index2], strlen($strings[$index1]) ) );
72 *** Test strncasecmp() function: with here-doc strings ***
H A Dstrncasecmp_variation6.phpt2 Test strncasecmp() function : usage variations - binary safe - all ASCII chars
5 /* Test strncasecmp() function with binary values passed to 'str1' & 'str2' */
7 echo "*** Test strncasecmp() function: with binary inputs ***\n";
11 …p through to get all 256 character's equivalent binary value, and check working of strncasecmp() */
17 var_dump( strncasecmp($str1, $str2, 8) ); //comparing all the 8-bits; expected: int(0)
18 var_dump( strncasecmp($str1, $str2, 4) ); //comparing only 4-bits; expected: int(0)
25 var_dump( strncasecmp($str1, $str2, 8) ); //comparing all the 8-bits; expected: int(1)
30 *** Test strncasecmp() function: with binary inputs ***
/PHP-8.0/Zend/tests/
H A D006.phpt2 strncasecmp() tests
7 var_dump(strncasecmp("", "", -1));
12 var_dump(strncasecmp("aef", "dfsgbdf", 0));
13 var_dump(strncasecmp("aef", "dfsgbdf", 10));
14 var_dump(strncasecmp("qwe", "qwer", 3));
15 var_dump(strncasecmp("qwerty", "QweRty", 6));
16 var_dump(strncasecmp("qwErtY", "qwer", 7));
17 var_dump(strncasecmp("q123", "Q123", 3));
18 var_dump(strncasecmp("01", "01", 1000));
22 strncasecmp(): Argument #3 ($length) must be greater than or equal to 0
/PHP-8.0/sapi/apache2handler/
H A Dmod_php.c25 #ifdef strncasecmp
26 # undef strncasecmp
H A Dapache_config.c23 #ifdef strncasecmp
24 # undef strncasecmp
66 if (!strncasecmp(value, "none", sizeof("none"))) { in real_value_hnd()
/PHP-8.0/ext/pdo/tests/
H A Dbug_43130.phpt8 if (!strncasecmp(getenv('PDOTEST_DSN'), 'sqlite', strlen('sqlite'))) die('skip not relevant for sql…
9 if (!strncasecmp(getenv('PDOTEST_DSN'), 'pgsql', strlen('pgsql'))) die('skip not relevant for pgsql…
10 if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))) die('skip not relevant for oci drive…
11 if (!strncasecmp(getenv('PDOTEST_DSN'), 'firebird', strlen('firebird'))) die('skip not relevant for…
12 if (!strncasecmp(getenv('PDOTEST_DSN'), 'odbc', strlen('odbc'))) die('skip not relevant for odbc dr…
H A Dbug_71885.phpt8 if (!strncasecmp(getenv('PDOTEST_DSN'), 'pgsql', strlen('pgsql'))) die('skip not relevant for pgsql…
9 if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))) die('skip not relevant for OCI drive…
10 if (!strncasecmp(getenv('PDOTEST_DSN'), 'odbc', strlen('odbc'))) die('skip inconsistent error messa…
H A Dbug_36798.phpt11 if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))){
13 } elseif (!strncasecmp(getenv('PDOTEST_DSN'), 'dblib', strlen('dblib'))) {
/PHP-8.0/ext/standard/
H A Dmail.c163 if (!strncasecmp("orig-date", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
170 if (!strncasecmp("from", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
177 if (!strncasecmp("sender", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
184 if (!strncasecmp("reply-to", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
191 if (!strncasecmp("to", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
195 if (!strncasecmp("cc", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
202 if (!strncasecmp("bcc", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
209 if (!strncasecmp("message-id", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
211 } else if (!strncasecmp("references", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
218 if (!strncasecmp("in-reply-to", ZSTR_VAL(key), ZSTR_LEN(key))) { in php_mail_build_headers()
[all …]
H A Dphp_fopen_wrapper.c189 if (!strncasecmp(path, "php://", 6)) { in php_stream_url_wrap_php()
193 if (!strncasecmp(path, "temp", 4)) { in php_stream_url_wrap_php()
196 if (!strncasecmp(path, "/maxmemory:", 11)) { in php_stream_url_wrap_php()
292 } else if (!strncasecmp(path, "fd/", 3)) { in php_stream_url_wrap_php()
339 } else if (!strncasecmp(path, "filter/", 7)) { in php_stream_url_wrap_php()
364 if (!strncasecmp(p, "read=", 5)) { in php_stream_url_wrap_php()
366 } else if (!strncasecmp(p, "write=", 6)) { in php_stream_url_wrap_php()
H A Dhttp_fopen_wrapper.c686 …&& ( tmp_line_len < sizeof("HTTP/1") - 1 || strncasecmp(tmp_line, "HTTP/1", sizeof("HTTP/1") - 1) ) in php_stream_url_wrap_http_ex()
781 if (!strncasecmp(http_header_line, "Location:", sizeof("Location:")-1)) { in php_stream_url_wrap_http_ex()
793 } else if (!strncasecmp(http_header_line, "Content-Type:", sizeof("Content-Type:")-1)) { in php_stream_url_wrap_http_ex()
795 } else if (!strncasecmp(http_header_line, "Content-Length:", sizeof("Content-Length:")-1)) { in php_stream_url_wrap_http_ex()
799 !strncasecmp(http_header_line, "Transfer-Encoding:", sizeof("Transfer-Encoding:")-1) in php_stream_url_wrap_http_ex()
800 && !strncasecmp(http_header_value, "Chunked", sizeof("Chunked")-1) in php_stream_url_wrap_http_ex()
852 if (strlen(location)<8 || (strncasecmp(location, "http://", sizeof("http://")-1) && in php_stream_url_wrap_http_ex()
853 strncasecmp(location, "https://", sizeof("https://")-1) && in php_stream_url_wrap_http_ex()
854 strncasecmp(location, "ftp://", sizeof("ftp://")-1) && in php_stream_url_wrap_http_ex()
855 strncasecmp(location, "ftps://", sizeof("ftps://")-1))) in php_stream_url_wrap_http_ex()
[all …]
H A Dphp_mail.h30 if (!strncasecmp(target, ZSTR_VAL(key), ZSTR_LEN(key))) { \
H A Dbrowscap.c316 if ((Z_STRLEN_P(arg2) == 2 && !strncasecmp(Z_STRVAL_P(arg2), "on", sizeof("on") - 1)) || in php_browscap_parser_cb()
317 (Z_STRLEN_P(arg2) == 3 && !strncasecmp(Z_STRVAL_P(arg2), "yes", sizeof("yes") - 1)) || in php_browscap_parser_cb()
318 (Z_STRLEN_P(arg2) == 4 && !strncasecmp(Z_STRVAL_P(arg2), "true", sizeof("true") - 1)) in php_browscap_parser_cb()
322 (Z_STRLEN_P(arg2) == 2 && !strncasecmp(Z_STRVAL_P(arg2), "no", sizeof("no") - 1)) || in php_browscap_parser_cb()
323 (Z_STRLEN_P(arg2) == 3 && !strncasecmp(Z_STRVAL_P(arg2), "off", sizeof("off") - 1)) || in php_browscap_parser_cb()
324 (Z_STRLEN_P(arg2) == 4 && !strncasecmp(Z_STRVAL_P(arg2), "none", sizeof("none") - 1)) || in php_browscap_parser_cb()
325 (Z_STRLEN_P(arg2) == 5 && !strncasecmp(Z_STRVAL_P(arg2), "false", sizeof("false") - 1)) in php_browscap_parser_cb()
/PHP-8.0/Zend/
H A Dzend_config.w32.h49 #define strncasecmp(s1, s2, n) _strnicmp(s1, s2, n) macro
/PHP-8.0/ext/standard/tests/streams/
H A Dbug74556.phpt5 if (!strncasecmp(PHP_OS, 'WIN', 3)) echo "skip Unix Only";
/PHP-8.0/ext/curl/
H A Dconfig.m442 if (strncasecmp(ptr, "OpenSSL/1.1", sizeof("OpenSSL/1.1")-1) == 0) {
46 if (strncasecmp(ptr, "OpenSSL", sizeof("OpenSSL")-1) == 0) {
/PHP-8.0/ext/zlib/
H A Dzlib_fopen_wrapper.c120 if (strncasecmp("compress.zlib://", path, 16) == 0) { in php_stream_gzopen()
122 } else if (strncasecmp("zlib:", path, 5) == 0) { in php_stream_gzopen()

Completed in 40 milliseconds

1234