當前位置: 首頁>>代碼示例>>PHP>>正文


PHP _to_unicode函數代碼示例

本文整理匯總了PHP中_to_unicode函數的典型用法代碼示例。如果您正苦於以下問題:PHP _to_unicode函數的具體用法?PHP _to_unicode怎麽用?PHP _to_unicode使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了_to_unicode函數的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: to_unicode

 /**
  * Takes an UTF-8 string and returns an array of ints representing the Unicode characters.
  * Astral planes are supported i.e. the ints in the output can be > 0xFFFF.
  * Occurrances of the BOM are ignored. Surrogates are not allowed.
  *
  * The Original Code is Mozilla Communicator client code.
  * The Initial Developer of the Original Code is Netscape Communications Corporation.
  * Portions created by the Initial Developer are Copyright (C) 1998 the Initial Developer.
  * Ported to PHP by Henri Sivonen <hsivonen@iki.fi>, see http://hsivonen.iki.fi/php-utf8/.
  * Slight modifications to fit with phputf8 library by Harry Fuecks <hfuecks@gmail.com>.
  *
  * @param   string   UTF-8 encoded string
  * @return  array    unicode code points
  * @return  boolean  FALSE if the string is invalid
  */
 public static function to_unicode($str)
 {
     if (!isset(self::$called[__FUNCTION__])) {
         require SYSPATH . 'core/utf8/' . __FUNCTION__ . EXT;
         // Function has been called
         self::$called[__FUNCTION__] = TRUE;
     }
     return _to_unicode($str);
 }
開發者ID:momoim,項目名稱:momo-api,代碼行數:24,代碼來源:utf8.php

示例2: to_unicode

 /**
  * Takes an UTF-8 string and returns an array of ints representing the Unicode characters.
  * Astral planes are supported i.e. the ints in the output can be > 0xFFFF.
  * Occurrences of the BOM are ignored. Surrogates are not allowed.
  *
  *     $array = UTF8::to_unicode($str);
  *
  * The Original Code is Mozilla Communicator client code.
  * The Initial Developer of the Original Code is Netscape Communications Corporation.
  * Portions created by the Initial Developer are Copyright (C) 1998 the Initial Developer.
  * Ported to PHP by Henri Sivonen <hsivonen@iki.fi>, see <http://hsivonen.iki.fi/php-utf8/>
  * Slight modifications to fit with phputf8 library by Harry Fuecks <hfuecks@gmail.com>
  *
  * @param   string  UTF-8 encoded string
  * @return  array   unicode code points
  * @return  FALSE   if the string is invalid
  */
 public static function to_unicode($str)
 {
     if (!isset(self::$called[__FUNCTION__])) {
         require SYSPATH . 'utf8' . DIRECTORY_SEPARATOR . __FUNCTION__ . EXT;
         // Function has been called
         self::$called[__FUNCTION__] = TRUE;
     }
     return _to_unicode($str);
 }
開發者ID:gilyaev,項目名稱:framework-bench,代碼行數:26,代碼來源:utf8.php

示例3: to_unicode

 public static function to_unicode($str)
 {
     if (!isset(UTF8::$called[__FUNCTION__])) {
         require JsonApiApplication::find_file("utf8", __FUNCTION__);
         // Function has been called
         UTF8::$called[__FUNCTION__] = TRUE;
     }
     return _to_unicode($str);
 }
開發者ID:benshez,項目名稱:DreamWeddingCeremonies,代碼行數:9,代碼來源:UTF8.php

示例4: to_unicode

 /**
  * Takes an UTF-8 string and returns an array of ints representing the Unicode characters.
  * Astral planes are supported i.e. the ints in the output can be > 0xFFFF.
  * Occurrances of the BOM are ignored. Surrogates are not allowed.
  *
  * The Original Code is Mozilla Communicator client code.
  * The Initial Developer of the Original Code is Netscape Communications Corporation.
  * Portions created by the Initial Developer are Copyright (C) 1998 the Initial Developer.
  * Ported to PHP by Henri Sivonen <hsivonen@iki.fi>, see http://hsivonen.iki.fi/php-utf8/.
  * Slight modifications to fit with phputf8 library by Harry Fuecks <hfuecks@gmail.com>.
  *
  * @param   string   UTF-8 encoded string
  * @return  array    unicode code points
  * @return  boolean  FALSE if the string is invalid
  */
 public static function to_unicode($str)
 {
     require_once dirname(__FILE__) . '/' . __FUNCTION__ . '.php';
     return _to_unicode($str);
 }
開發者ID:abhinay100,項目名稱:forma_app,代碼行數:20,代碼來源:lib.utf8.php

示例5: to_unicode

 /**
  * Takes an UTF-8 string and returns an array of ints representing the Unicode characters.
  * Astral planes are supported i.e. the ints in the output can be > 0xFFFF.
  * Occurrences of the BOM are ignored. Surrogates are not allowed.
  *
  *     $array = UTF8::to_unicode($str);
  *
  * The Original Code is Mozilla Communicator client code.
  * The Initial Developer of the Original Code is Netscape Communications Corporation.
  * Portions created by the Initial Developer are Copyright (C) 1998 the Initial Developer.
  * Ported to PHP by Henri Sivonen <hsivonen@iki.fi>, see <http://hsivonen.iki.fi/php-utf8/>
  * Slight modifications to fit with phputf8 library by Harry Fuecks <hfuecks@gmail.com>
  *
  * @param   string  $str    UTF-8 encoded string
  * @return  array   unicode code points
  * @return  FALSE   if the string is invalid
  */
 public static function to_unicode($str)
 {
     if (!isset(UTF8::$called[__FUNCTION__])) {
         require Kohana::find_file('utf8', __FUNCTION__);
         // Function has been called
         UTF8::$called[__FUNCTION__] = TRUE;
     }
     return _to_unicode($str);
 }
開發者ID:Chinese1904,項目名稱:openclassifieds2,代碼行數:26,代碼來源:UTF8.php

示例6: to_unicode

 /**
  * Takes an UTF-8 string and returns an array of ints representing the Unicode characters
  *
  * Astral planes are supported i.e. the ints in the output can be > 0xFFFF.
  * Occurrences of the BOM are ignored. Surrogates are not allowed.
  *
  * Example:
  * ~~~
  * $array = UTF8::to_unicode($str);
  * ~~~
  *
  * The Original Code is Mozilla Communicator client code.
  * The Initial Developer of the Original Code is Netscape Communications Corporation.
  * Portions created by the Initial Developer are Copyright (C) 1998 the Initial Developer.
  * Ported to PHP by Henri Sivonen <hsivonen@iki.fi>, see <http://hsivonen.iki.fi/php-utf8/>
  * Slight modifications to fit with phputf8 library by Harry Fuecks <hfuecks@gmail.com>
  *
  * @param   string  $str  UTF-8 encoded string
  *
  * @return  array    mixed
  *
  * @uses    Kohana::find_file
  */
 public static function to_unicode($str)
 {
     UTF8::_load(__FUNCTION__);
     return _to_unicode($str);
 }
開發者ID:ultimateprogramer,項目名稱:cms,代碼行數:28,代碼來源:utf8.php


注:本文中的_to_unicode函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。