Home  >  Article  >  Backend Development  >  PHP encoding conversion_PHP tutorial

PHP encoding conversion_PHP tutorial

WBOY
WBOYOriginal
2016-07-21 15:15:001000browse

SELECT COLLATIONPROPERTY('Chinese_PRC_Stroke_CI_AI_KS_WS', 'CodePage')

The return value is 936, which is GBK encoding.

936 Simplified Chinese GBK
950 Traditional Chinese BIG5
437 American/Canadian English
932 Japanese
949 Korean
866 Russian
65001 unicode UFT-8
If you must set the encoding of the php file to utf-8, you need to convert the encoding:

print_r($rs[mb_convert_encoding("Customer encoding","GBK","UTF -8")]);//Print the record array

This way there will be no problem.



http://www.bkjia.com/PHPjc/326145.html

www.bkjia.com

true

TechArticleSELECT COLLATIONPROPERTY('Chinese_PRC_Stroke_CI_AI_KS_WS', 'CodePage') returns 936, which is GBK encoding. 936 Simplified Chinese GBK 950 Traditional Chinese BIG5 437 United States/Canada English 932 Japanese...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn