位置: 编程技术 - 正文
推荐整理分享PHP:iconv_strrpos()的用法_iconv函数,希望有所帮助,仅作参考,欢迎阅读内容。
文章相关热门搜索词:,内容如对您有帮助,希望把文章链接给更多的朋友!
(PHP 5)
iconv_strrpos — Finds the last occurrence of a needle within a haystack
说明 int iconv_strrpos ( string $haystack , string $needle [, string $charset = ini_get("iconv.internal_encoding") ] )Finds the last occurrence of a needle within a haystack.
In contrast to strrpos(), the return value of iconv_strrpos() is the number of characters that appear before the needle, rather than the offset in bytes to the position where the needle has been found. The characters are counted on the basis of the specified character set charset.
参数haystack
The entire string.
needleThe searched substring.
charsetIf charset parameter is omitted, string are assumed to be encoded in iconv.internal_encoding.
If haystack or needle is not a string, it is converted to a string and applied as the ordinal value of a character.
返回值Returns the numeric position of the last occurrence of needle in haystack.
If needle is not found, iconv_strrpos() will return FALSE.
Warning此函数可能返回布尔值FALSE,但也可能返回等同于 FALSE 的非布尔值。请阅读 布尔类型章节以获取更多信息。应使用===运算符来测试此函数的返回值。
参见strrpos() - 计算指定字符串在目标字符串中最后一次出现的位置 iconv_strpos() - Finds position of first occurrence of a needle within a haystack mb_strrpos() - 查找字符串在一个字符串中最后出现的位置
PHP:iconv_strpos()的用法_iconv函数 iconv_strpos(PHP5)iconv_strposFindspositionoffirstoccurrenceofaneedlewithinahaystack说明inticonv_strpos(string$haystack,string$needle[,int$offset=0[,string$charset=ini_get(iconv.internal_encoding)]]
PHP:iconv_mime_encode()的用法_iconv函数 iconv_mime_encode(PHP5)iconv_mime_encodeComposesaMIMEheaderfield说明stringiconv_mime_encode(string$field_name,string$field_value[,array$preferences=NULL])Composesandreturnsastringthatrepresentsavali
PHP:iconv_strlen()的用法_iconv函数 iconv_strlen(PHP5)iconv_strlen返回字符串的字符数统计说明inticonv_strlen(string$str[,string$charset=ini_get(iconv.internal_encoding)])和strlen()不同的是,iconv_strlen()统计了给
标签: PHP:iconv_strrpos()的用法_iconv函数
本文链接地址:https://www.jiuchutong.com/biancheng/285158.html 转载请保留说明!友情链接: 武汉网站建设