当前位置: 首页>>代码示例>>PHP>>正文


PHP _strrpos函数代码示例

本文整理汇总了PHP中_strrpos函数的典型用法代码示例。如果您正苦于以下问题:PHP _strrpos函数的具体用法?PHP _strrpos怎么用?PHP _strrpos使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了_strrpos函数的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: strrpos

 /**
  * Finds position of last occurrence of a char in a UTF-8 string. This is
  * a UTF8-aware version of [strrpos](http://php.net/strrpos).
  *
  *     $position = UTF8::strrpos($str, $search);
  *
  * @author  Harry Fuecks <hfuecks@gmail.com>
  * @param   string   haystack
  * @param   string   needle
  * @param   integer  offset from which character in haystack to start searching
  * @return  integer  position of needle
  * @return  boolean  FALSE if the needle is not found
  * @uses    UTF8::$server_utf8
  */
 public static function strrpos($str, $search, $offset = 0)
 {
     if (UTF8::$server_utf8) {
         return mb_strrpos($str, $search, $offset, Kohana::$charset);
     }
     if (!isset(self::$called[__FUNCTION__])) {
         require SYSPATH . 'utf8' . DIRECTORY_SEPARATOR . __FUNCTION__ . EXT;
         // Function has been called
         self::$called[__FUNCTION__] = TRUE;
     }
     return _strrpos($str, $search, $offset);
 }
开发者ID:gilyaev,项目名称:framework-bench,代码行数:26,代码来源:utf8.php

示例2: strrpos

 /**
  * Finds position of last occurrence of a char in a UTF-8 string.
  * @see http://php.net/strrpos
  *
  * @author  Harry Fuecks <hfuecks@gmail.com>
  *
  * @param   string   haystack
  * @param   string   needle
  * @param   integer  offset from which character in haystack to start searching
  * @return  integer  position of needle
  * @return  boolean  FALSE if the needle is not found
  */
 public static function strrpos($str, $search, $offset = 0)
 {
     if (!isset(self::$called[__FUNCTION__])) {
         require SYSPATH . 'core/utf8/' . __FUNCTION__ . EXT;
         // Function has been called
         self::$called[__FUNCTION__] = TRUE;
     }
     return _strrpos($str, $search, $offset);
 }
开发者ID:momoim,项目名称:momo-api,代码行数:21,代码来源:utf8.php

示例3: strrpos

 static function strrpos($str, $search, $offset = 0)
 {
     if (UTF8::$server_utf8) {
         return mb_strrpos($str, $search, $offset, JsonApiApplication::$charset);
     }
     if (!isset(UTF8::$called[__FUNCTION__])) {
         require JsonApiApplication::find_file("utf8", __FUNCTION__);
         // Function has been called
         UTF8::$called[__FUNCTION__] = TRUE;
     }
     return _strrpos($str, $search, $offset);
 }
开发者ID:benshez,项目名称:DreamWeddingCeremonies,代码行数:12,代码来源:UTF8.php

示例4: strrpos

 /**
  * Finds position of last occurrence of a char in a UTF-8 string.
  * @see http://php.net/strrpos
  *
  * @author  Harry Fuecks <hfuecks@gmail.com>
  *
  * @param   string   haystack
  * @param   string   needle
  * @param   integer  offset from which character in haystack to start searching
  * @return  integer  position of needle
  * @return  boolean  FALSE if the needle is not found
  */
 public static function strrpos($str, $search, $offset = 0)
 {
     require_once dirname(__FILE__) . '/' . __FUNCTION__ . '.php';
     return _strrpos($str, $search, $offset);
 }
开发者ID:abhinay100,项目名称:forma_app,代码行数:17,代码来源:lib.utf8.php

示例5: strrpos

 /**
  * Finds position of last occurrence of a char in a UTF-8 string. This is
  * a UTF8-aware version of [strrpos](http://php.net/strrpos).
  *
  *     $position = UTF8::strrpos($str, $search);
  *
  * @author  Harry Fuecks <hfuecks@gmail.com>
  * @param   string  $str    haystack
  * @param   string  $search needle
  * @param   integer $offset offset from which character in haystack to start searching
  * @return  integer position of needle
  * @return  boolean FALSE if the needle is not found
  * @uses    UTF8::$server_utf8
  */
 public static function strrpos($str, $search, $offset = 0)
 {
     if (UTF8::$server_utf8) {
         return mb_strrpos($str, $search, $offset, Kohana::$charset);
     }
     if (!isset(UTF8::$called[__FUNCTION__])) {
         require Kohana::find_file('utf8', __FUNCTION__);
         // Function has been called
         UTF8::$called[__FUNCTION__] = TRUE;
     }
     return _strrpos($str, $search, $offset);
 }
开发者ID:Chinese1904,项目名称:openclassifieds2,代码行数:26,代码来源:UTF8.php

示例6: strrpos

 /**
  * Finds position of last occurrence of a char in a UTF-8 string
  *
  * This is a UTF8-aware version of [strrpos](http://php.net/strrpos).
  *
  * Example:
  * ~~~
  * $position = UTF8::strrpos($str, $search);
  * ~~~
  *
  * @author  Harry Fuecks <hfuecks@gmail.com>
  *
  * @param   string   $str     Haystack
  * @param   string   $search  Needle
  * @param   integer  $offset  Offset from which character in haystack to start searching [Optional]
  *
  * @return  mixed
  *
  * @uses    UTF8::$server_utf8
  * @uses    Kohana::$charset
  * @uses    Kohana::find_file
  */
 public static function strrpos($str, $search, $offset = 0)
 {
     if (self::$server_utf8) {
         return mb_strrpos($str, $search, $offset, Kohana::$charset);
     }
     UTF8::_load(__FUNCTION__);
     return _strrpos($str, $search, $offset);
 }
开发者ID:ultimateprogramer,项目名称:cms,代码行数:30,代码来源:utf8.php

示例7: strrpos

 /**
  * Finds position of last occurrence of a char in a UTF-8 string. This is
  * a UTF8-aware version of [strrpos](http://php.net/strrpos).
  *
  *     $position = UTF8::strrpos($str, $search);
  *
  * @author  Harry Fuecks <hfuecks@gmail.com>
  * @param   string  $str    haystack
  * @param   string  $search needle
  * @param   integer $offset offset from which character in haystack to start searching
  * @return  integer position of needle
  * @return  boolean false if the needle is not found
  * @uses    UTF8::$server_utf8
  */
 public static function strrpos($str, $search, $offset = 0)
 {
     if (UTF8::$server_utf8) {
         return mb_strrpos($str, $search, $offset, Phalcana::$charset);
     }
     if (!isset(UTF8::$called[__FUNCTION__])) {
         require Phalcana::$di->get('fs')->findFile('utf8', __FUNCTION__);
         // Function has been called
         UTF8::$called[__FUNCTION__] = true;
     }
     return _strrpos($str, $search, $offset);
 }
开发者ID:braf,项目名称:phalcana-core,代码行数:26,代码来源:UTF8.php


注:本文中的_strrpos函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。