Data communication between Android mobile terminal and PHP and MySQL based on JSON. Chinese garbled problem

WBOY
Release: 2016-08-08 09:25:05
Original
1161 people have browsed it

Original text

Server-side Chinese character encoding: gb2312

The JSON data sent from the server is always garbled on the Android side

Solution:

BufferedReader reader = new BufferedReader(
							new InputStreamReader(is,"GBK"));
Copy after login

The above introduces the Chinese garbled problem of JSON-based Android mobile terminal and PHP and MySQL data communication, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials.

source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template