【乱码】总结

来源:互联网 发布:php curl 断点续传 编辑:程序博客网 时间:2024/05/29 05:03

JAVA支持的字符集:

Charset

Description

US-ASCIISeven-bit ASCII, a.k.a. ISO646-US, a.k.a. the Basic Latin block of the Unicode character setISO-8859-1  ISO Latin Alphabet No. 1, a.k.a. ISO-LATIN-1UTF-8Eight-bit UCS Transformation FormatUTF-16BESixteen-bit UCS Transformation Format, big-endian byte orderUTF-16LESixteen-bit UCS Transformation Format, little-endian byte orderUTF-16Sixteen-bit UCS Transformation Format, byte order identified by an optional byte-order mark


1、request.setCharacterEncoding("UTF-8"); //只对post方式有效,对get方式无效

0 0
原创粉丝点击