mb_strpos — Find position of first occurrence of string in a string
mb_strpos — 查找字符串在另一个字符串中首次出现的位置
Description
int mb_strpos (
string $haystack ,
string $needle [,
int $offset = 0 [,
string $encoding = mb_internal_encoding() ]]
)
//Finds position of the first occurrence of a string in a string.// 查找 string 在一个 string 中首次出现的位置。//Performs a multi-byte safe strpos() operation based on number of characters. The first character's position is 0, the second character position is 1, and so on.// 基于字符数执行一个多字节安全的 strpos() 操作。 第一个字符的位置是 0,第二个字符的位置是 1,以此类推。
Parameters
haystack
The string being checked.
要被检查的 string。
needle
The string to find in haystack. In contrast with strpos(), numeric values are not applied as the ordinal value of a character.
mb_strpos (PHP 4 >= 4.0.6, PHP 5, PHP 7) mb_strpos — Find position of first occurrence of string in a string mb_strpos — 查找字符串在另一个字符串中首次出现的位置 Descriptionint mb_strpos ( stri