亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? unicode.php

?? CMS系統 提供學習研究修改最好了 比流行的一些CMS簡單 但是更容易理解 是幫助你學習PHPCMS系統的好東東哦
?? PHP
?? 第 1 頁 / 共 4 頁
字號:
<?php/******************************************************************************** Filename:     Unicode.php** Description:  Provides functions for handling Unicode strings in PHP without*               needing to configure the non-default mbstring extension** Author:       Evan Hunter** Date:         27/7/2004** Project:      JPEG Metadata** Revision:     1.10** Changes:      1.00 -> 1.10 : Added the following functions:*                              smart_HTML_Entities*                              smart_htmlspecialchars*                              HTML_UTF16_UnEscape*                              HTML_UTF8_UnEscape*                              changed HTML_UTF8_Escape and HTML_UTF16_Escape to*                              use smart_htmlspecialchars, so that characters which*                              were already escaped would remain intact*** URL:          http://electronics.ozhiker.com** License:      This file is part of the PHP JPEG Metadata Toolkit.**               The PHP JPEG Metadata Toolkit is free software; you can*               redistribute it and/or modify it under the terms of the*               GNU General Public License as published by the Free Software*               Foundation; either version 2 of the License, or (at your*               option) any later version.**               The PHP JPEG Metadata Toolkit is distributed in the hope*               that it will be useful, but WITHOUT ANY WARRANTY; without*               even the implied warranty of MERCHANTABILITY or FITNESS*               FOR A PARTICULAR PURPOSE.  See the GNU General Public License*               for more details.**               You should have received a copy of the GNU General Public*               License along with the PHP JPEG Metadata Toolkit; if not,*               write to the Free Software Foundation, Inc., 59 Temple*               Place, Suite 330, Boston, MA  02111-1307  USA**               If you require a different license for commercial or other*               purposes, please contact the author: evan@ozhiker.com*******************************************************************************/// TODO: UTF-16 functions have not been tested fully/******************************************************************************** Unicode UTF-8 Encoding Functions** Description:  UTF-8 is a Unicode encoding system in which extended characters*               use only the upper half (128 values) of the byte range, thus it*               allows the use of normal 7-bit ASCII text.*               7-Bit ASCII will pass straight through UTF-8 encoding/decoding without change*** The encoding is as follows:* Unicode Value          :  Binary representation (x=data bit)*--------------------------------------------------------------------------------* U-00000000 - U-0000007F:  0xxxxxxx                      <- This is 7-bit ASCII* U-00000080 - U-000007FF:  110xxxxx 10xxxxxx* U-00000800 - U-0000FFFF:  1110xxxx 10xxxxxx 10xxxxxx* U-00010000 - U-001FFFFF:  11110xxx 10xxxxxx 10xxxxxx 10xxxxxx* U-00200000 - U-03FFFFFF:  111110xx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx* U-04000000 - U-7FFFFFFF:  1111110x 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx*--------------------------------------------------------------------------------*******************************************************************************//******************************************************************************** Unicode UTF-16 Encoding Functions** Description:  UTF-16 is a Unicode encoding system uses 16 bit values for representing*               characters.*               It also has an extended set of characters available by the use*               of surrogate pairs, which are a pair of 16 bit values, giving a*               total data length of 20 useful bits.*** The encoding is as follows:* Unicode Value          :  Binary representation (x=data bit)*--------------------------------------------------------------------------------* U-000000 - U-00D7FF:  xxxxxxxx xxxxxxxx* U-00D800 - U-00DBFF:  Not available - used for high surrogate pairs* U-00DC00 - U-00DFFF:  Not available - used for low surrogate pairs  U-00E000 - U-00FFFF:  xxxxxxxx xxxxxxxx* U-010000 - U-10FFFF:  110110ww wwxxxxxx  110111xx xxxxxxxx      ( wwww = (uni-0x10000)/0x10000 )*--------------------------------------------------------------------------------**  Surrogate pair Calculations**  $hi = ($uni - 0x10000) / 0x400 + 0xD800;*  $lo = ($uni - 0x10000) % 0x400 + 0xDC00;***  $uni = 0x10000 + ($hi - 0xD800) * 0x400 + ($lo - 0xDC00);********************************************************************************//******************************************************************************** Function:     UTF8_fix** Description:  Checks a string for badly formed Unicode UTF-8 coding and*               returns the same string containing only the parts which*               were properly formed UTF-8 data.** Parameters:   utf8_text - a string with possibly badly formed UTF-8 data** Returns:      output - the well formed UTF-8 version of the string*******************************************************************************/function UTF8_fix( $utf8_text ){        // Initialise the current position in the string        $pos = 0;        // Create a string to accept the well formed output        $output = "" ;        // Cycle through each group of bytes, ensuring the coding is correct        while ( $pos < strlen( $utf8_text ) )        {                // Retreive the current numerical character value                $chval = ord($utf8_text{$pos});                // Check what the first character is - it will tell us how many bytes the                // Unicode value covers                if ( ( $chval >= 0x00 ) && ( $chval <= 0x7F ) )                {                        // 1 Byte UTF-8 Unicode (7-Bit ASCII) Character                        $bytes = 1;                }                else if ( ( $chval >= 0xC0 ) && ( $chval <= 0xDF ) )                {                        // 2 Byte UTF-8 Unicode Character                        $bytes = 2;                }                else if ( ( $chval >= 0xE0 ) && ( $chval <= 0xEF ) )                {                        // 3 Byte UTF-8 Unicode Character                        $bytes = 3;                }                else if ( ( $chval >= 0xF0 ) && ( $chval <= 0xF7 ) )                {                        // 4 Byte UTF-8 Unicode Character                        $bytes = 4;                }                else if ( ( $chval >= 0xF8 ) && ( $chval <= 0xFB ) )                {                        // 5 Byte UTF-8 Unicode Character                        $bytes = 5;                }                else if ( ( $chval >= 0xFC ) && ( $chval <= 0xFD ) )                {                        // 6 Byte UTF-8 Unicode Character                        $bytes = 6;                }                else                {                        // Invalid Code - skip character and do nothing                        $bytes = 0;                        $pos++;                }                // check that there is enough data remaining to read                if (($pos + $bytes - 1) < strlen( $utf8_text ) )                {                        // Cycle through the number of bytes specified,                        // copying them to the output string                        while ( $bytes > 0 )                        {                                $output .= $utf8_text{$pos};                                $pos++;                                $bytes--;                        }                }                else                {                        break;                }        }        // Return the result        return $output;}/******************************************************************************* End of Function:     UTF8_fix******************************************************************************//******************************************************************************** Function:     UTF16_fix** Description:  Checks a string for badly formed Unicode UTF-16 coding and*               returns the same string containing only the parts which*               were properly formed UTF-16 data.** Parameters:   utf16_text - a string with possibly badly formed UTF-16 data*               MSB_first - True will cause processing as Big Endian UTF-16 (Motorola, MSB first)*                           False will cause processing as Little Endian UTF-16 (Intel, LSB first)** Returns:      output - the well formed UTF-16 version of the string*******************************************************************************/function UTF16_fix( $utf16_text, $MSB_first ){        // Initialise the current position in the string        $pos = 0;        // Create a string to accept the well formed output        $output = "" ;        // Cycle through each group of bytes, ensuring the coding is correct        while ( $pos < strlen( $utf16_text ) )        {                // Retreive the current numerical character value                $chval1 = ord($utf16_text{$pos});                // Skip over character just read                $pos++;                // Check if there is another character available                if ( $pos  < strlen( $utf16_text ) )                {                        // Another character is available - get it for the second half of the UTF-16 value                        $chval2 = ord( $utf16_text{$pos} );                }                else                {                        // Error - no second byte to this UTF-16 value - end processing                        continue 1;                }                // Skip over character just read                $pos++;                // Calculate the 16 bit unicode value                if ( $MSB_first )                {                        // Big Endian                        $UTF16_val = $chval1 * 0x100 + $chval2;                }                else                {                        // Little Endian                        $UTF16_val = $chval2 * 0x100 + $chval1;                }                if ( ( ( $UTF16_val >= 0x0000 ) && ( $UTF16_val <= 0xD7FF ) ) ||                     ( ( $UTF16_val >= 0xE000 ) && ( $UTF16_val <= 0xFFFF ) ) )                {                        // Normal Character (Non Surrogate pair)                        // Add it to the output                        $output .= chr( $chval1 ) . chr ( $chval2 );                }                else if ( ( $UTF16_val >= 0xD800 ) && ( $UTF16_val <= 0xDBFF ) )                {                        // High surrogate of a surrogate pair                        // Now we need to read the low surrogate                        // Check if there is another 2 characters available                        if ( ( $pos + 3 ) < strlen( $utf16_text ) )                        {                                // Another 2 characters are available - get them                                $chval3 = ord( $utf16_text{$pos} );                                $chval4 = ord( $utf16_text{$pos+1} );                                // Calculate the second 16 bit unicode value                                if ( $MSB_first )                                {                                        // Big Endian                                        $UTF16_val2 = $chval3 * 0x100 + $chval4;                                }                                else

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色天使久久综合网天天| 亚洲品质自拍视频| 精东粉嫩av免费一区二区三区| 91福利小视频| 亚洲地区一二三色| 91麻豆精品国产91久久久| 麻豆久久一区二区| 欧美成人一区二区三区片免费 | 老司机精品视频导航| 日韩一区二区在线观看视频 | 国产精品自拍一区| 国产精品免费看片| 欧洲一区在线观看| 免费久久99精品国产| 久久一夜天堂av一区二区三区 | 日韩高清不卡一区二区三区| 日韩欧美一区在线| 国产不卡视频在线观看| 亚洲男人的天堂在线观看| 精品1区2区3区| 久久99精品国产.久久久久久| 久久天天做天天爱综合色| 成人美女视频在线观看18| 一区二区三区四区视频精品免费 | 国产98色在线|日韩| 亚洲视频一二三区| 欧美日韩国产免费| 国产精品一区在线观看乱码| 亚洲欧美日韩国产另类专区| 在线观看91精品国产麻豆| 国产精品亚洲专一区二区三区| 自拍偷拍亚洲激情| 日韩欧美自拍偷拍| 一本在线高清不卡dvd| 麻豆精品国产传媒mv男同| 国产欧美一区二区精品性色超碰| 欧美亚洲图片小说| 国产成人一级电影| 五月天久久比比资源色| 国产视频亚洲色图| 91精品婷婷国产综合久久竹菊| 国产成人亚洲综合色影视| 亚洲成av人片一区二区| 国产精品美日韩| 欧美电视剧免费观看| 91成人国产精品| 国产成人99久久亚洲综合精品| 天天色天天爱天天射综合| 国产精品乱码妇女bbbb| 欧美成人福利视频| 欧美日韩精品福利| 99视频在线精品| 国产剧情av麻豆香蕉精品| 天天综合网天天综合色 | 欧美色综合久久| 成人av资源站| 蓝色福利精品导航| 亚洲图片另类小说| 日韩免费观看2025年上映的电影| 国产盗摄一区二区| 婷婷亚洲久悠悠色悠在线播放| 日本一区二区三区视频视频| 欧美美女喷水视频| 成人污污视频在线观看| 亚洲成人一区二区| 亚洲少妇最新在线视频| 久久精品亚洲乱码伦伦中文| 欧美理论在线播放| 99精品视频在线观看免费| 亚洲在线中文字幕| 国产农村妇女精品| 日韩亚洲欧美成人一区| 欧美综合久久久| 成人福利视频网站| 久久草av在线| 午夜国产不卡在线观看视频| 亚洲靠逼com| 中文字幕国产一区二区| 精品国产乱码久久久久久影片| 欧美日韩免费电影| 成人激情小说网站| 国产在线观看一区二区| 欧美bbbbb| 婷婷丁香久久五月婷婷| 一区二区三区中文免费| 亚洲精品第1页| 亚洲人成影院在线观看| 国产精品免费久久| 国产精品每日更新在线播放网址| 久久亚洲精精品中文字幕早川悠里| 欧美喷潮久久久xxxxx| 99久久精品一区二区| 91在线码无精品| 粉嫩av一区二区三区| 国产精品69久久久久水密桃| 国产综合久久久久久鬼色| 日本欧美一区二区三区乱码| 日韩精品欧美精品| 视频一区免费在线观看| 亚洲国产一区二区在线播放| 亚洲精品福利视频网站| 亚洲激情网站免费观看| 亚洲免费电影在线| 亚洲妇女屁股眼交7| 亚洲高清免费观看 | 国产精品69毛片高清亚洲| 免费在线观看日韩欧美| 老司机一区二区| 久久精品99国产精品| 国产原创一区二区三区| 国产一区二区三区精品欧美日韩一区二区三区| 日韩电影在线一区二区三区| 丝袜诱惑亚洲看片| 青草av.久久免费一区| 久久99国产精品免费网站| 国产成人h网站| thepron国产精品| 欧美日韩视频在线观看一区二区三区| 波多野洁衣一区| 欧美午夜在线一二页| 51午夜精品国产| 久久久久亚洲蜜桃| 国产精品色哟哟| 亚洲国产精品欧美一二99| 日韩av在线免费观看不卡| 精品伊人久久久久7777人| 精品在线观看免费| 欧美亚洲国产怡红院影院| 在线播放视频一区| 久久日韩精品一区二区五区| 亚洲国产经典视频| 午夜精品一区在线观看| 久88久久88久久久| 成人app网站| 777午夜精品免费视频| 日韩一区二区视频| 国产精品人人做人人爽人人添| 一区二区三区精品视频| 精彩视频一区二区| 色94色欧美sute亚洲线路一久| 91.com视频| 国产片一区二区| 天天操天天色综合| thepron国产精品| 日韩一二三四区| ㊣最新国产の精品bt伙计久久| 亚洲伊人色欲综合网| gogogo免费视频观看亚洲一| 在线成人小视频| 国产精品国产三级国产a | 亚洲不卡av一区二区三区| 韩国v欧美v日本v亚洲v| 欧美视频日韩视频在线观看| 国产午夜精品一区二区三区视频| 亚洲福利一区二区三区| 91免费视频大全| 国产亚洲福利社区一区| 日韩高清在线不卡| 日本高清视频一区二区| 国产丝袜在线精品| 亚洲成a人片综合在线| 在线视频中文字幕一区二区| 国产日韩欧美精品电影三级在线| 五月天一区二区| 91片黄在线观看| 欧美国产综合一区二区| 蜜桃91丨九色丨蝌蚪91桃色| 欧美在线观看一区| 国产欧美一区二区三区网站 | 欧美一级黄色录像| 艳妇臀荡乳欲伦亚洲一区| gogogo免费视频观看亚洲一| 久久久国产午夜精品| 日韩高清不卡一区二区三区| 欧美在线观看一二区| 国产欧美精品日韩区二区麻豆天美| 青青草国产成人av片免费| 欧美日韩精品综合在线| 亚洲一区电影777| 菠萝蜜视频在线观看一区| 亚洲私人影院在线观看| 99re热视频这里只精品| 国产精品国产三级国产普通话蜜臀 | 久久久国产精华| 激情小说亚洲一区| 欧美精品一区二区三区蜜桃视频| 日韩av一级片| 日韩亚洲欧美高清| 免费视频最近日韩| 欧美sm极限捆绑bd| 精品无人区卡一卡二卡三乱码免费卡| 日韩一级欧美一级| 青青国产91久久久久久| 日韩免费高清电影| 国产永久精品大片wwwapp| 91精品国产综合久久久久久久| 亚洲一区二区四区蜜桃| 精品视频免费在线| 日韩国产高清在线| 精品久久国产字幕高潮|