strpbrk
(PHP 5)
strpbrk — 在字符串中查找一组字符的任何一个字符
说明
string strpbrk
( string $haystack
, string $char_list
)
参数
-
haystack
-
在此字符串中查找 char_list。
-
char_list
-
该参数区分大小写。
返回值
返回一个以找到的字符开始的子字符串。如果没有找到,则返回 FALSE。
范例
Example #1 strpbrk() 范例
<?php
$text = 'This is a Simple text.';
// 输出 "is is a Simple text.",因为 'i' 先被匹配
echo strpbrk($text, 'mi');
// 输出 "Simple text.",因为字符区分大小写
echo strpbrk($text, 'S');
?>
addcslashes
addslashes
bin2hex
chop
chr
chunk_split
convert_cyr_string
convert_uudecode
convert_uuencode
count_chars
crc32
crypt
echo
explode
fprintf
get_html_translation_table
hebrev
hebrevc
hex2bin
htmlentities
htmlspecialchars
htmlspecialchars_decode
html_entity_decode
implode
join
levenshtein
localeconv
ltrim
md5
md5_file
metaphone
money_format
nl2br
nl_langinfo
number_format
ord
parse_str
print
printf
quoted_printable_decode
quoted_printable_encode
quotemeta
rtrim
setlocale
sha1
sha1_file
similar_text
soundex
sprintf
sscanf
strcasecmp
strchr
strcmp
strcoll
strcspn
stripcslashes
stripos
stripslashes
strip_tags
stristr
strlen
strnatcasecmp
strnatcmp
strncasecmp
strncmp
strpbrk
strpos
strrchr
strrev
strripos
strrpos
strspn
strstr
strtok
strtolower
strtoupper
strtr
str_getcsv
str_ireplace
str_pad
str_repeat
str_replace
str_rot13
str_shuffle
str_split
str_word_count
substr
substr_compare
substr_count
substr_replace
trim
ucfirst
ucwords
vfprintf
vprintf
vsprintf
wordwrap
PHP
MySQL
HTML
CSS
JavaScript
MSSQL
AJAX
.NET
JSP
Linux
Mac
ASP
服务器
SQL
jQuery
C#
C++
java
Android
IOS
oracle
MongoDB
SQLite
wamp
交通频道