php专区

 首页 > php专区 > PHP应用 > php函数大全 > php入门教程:stripos 实例教程

php入门教程:stripos 实例教程

分享到:
【字体:
导读:
          php入门教程:stripos 实例教程定义和用法该stripos ( )函数返回位置,首次出现了字串的开始位置。如果字符串是没有发现,此功能返回FALSE 。stripos(string,find,start)参数 说明string: 必须先,find:

 

php入门教程:stripos  实例教程

定义和用法
该stripos ( )函数返回位置,首次出现了字串的开始位置。

如果字符串是没有发现,此功能返回FALSE 。

stripos(string,find,start)
参数 说明

string: 必须先,

find: 必须要查找的字符串

start: Optional. Specifies where to begin the search


好了下面我们来看看.stripos例子.


echo stripos("Hello world!","WO");
?>


输出结果为.
6

分享到:
判断字符长度函数strlen实例教程
  定义和用法 该strlen ( )函数返回的长度字符串。 他的作用是计算字字符长度的,中文一个字为2 语法 strlen(string)   Parameter Description string Required. Specifies the string to check 来看个简单的例子吧.     输出为   12
php基础教程strrpos 函数 使用教程
  strrpos 与 strripos用法相同的,下面我们来看看吧. 定义和用法 该strrpos ( )函数判断 find是否会出现在string里面。 这个函数如果存在的成功,否则返回FALSE 。 strrpos 语法 strrpos(string,find,start) string:必需。指定字符串搜索 find:所需。指定的字符串找到 start:可选。指定从何处开始搜寻 注...
  •         php迷,一个php技术的分享社区,专属您自己的技术摘抄本、收藏夹。
  • 在这里……