substr('6tTPnWsXBBmF5FZ2·mPbpBcZh8D76PrBP~', 16, 1);
E:\Apache\htdocs\site\application\controllers\Welcome.php:16:string '?' (length=1)
mb_substr('6tTPnWsXBBmF5FZ2·mPbpBcZh8D76PrBP~', 16, 1);
E:\Apache\htdocs\site\application\controllers\Welcome.php:17:string '·' (length=2)
substr 是按位元組數截取,mb_substr 是按邏輯欄位個數截取,才會出現上述情況,可參閱 https://bugs.php.net/bug.php?id=66069
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/5052.html
標籤:PHP
