html Solutions to Chinese garbled tags: 1. When receiving in the background, use the "ISO-8859-1" international standard for transcoding; 2. Directly transcode URLs with Chinese characters in them. code, and then decode it when receiving in the background.
The operating environment of this article: Windows7 system, HTML5&&CSS3 version, Dell G3 computer.
The a tag of html transmits Chinese characters to the background as garbled characters
Problem description:
String title = request.getParameter("title"); byte[] tb=title.getBytes("ISO-8859-1"); title=new String(tb);
Method 2: Transcode the url, that is, directly transcode the URL with Chinese characters in it, and then decode it when receiving it in the background. That's it.
:
## When receiving: ##r
[Recommended Learning:
HTML video tutorial】
The above is the detailed content of How to solve the Chinese garbled problem of html tag. For more information, please follow other related articles on the PHP Chinese website!