如何修复项目中的字符集?
How can I fix the charset on my project?
它是一个 JPA 并且
我在数据库上得到 "descri��o" 这个词,在我的服务器端调试中,就在持久性之前,当它从 Form 接收时,它就像 "descri��o" .
我有一个表单,<form action="..." method="post">
,它有一些字段并发送到 REST 服务,@post,我的断点就在其中并显示它。
我在表格HTML页面的头部使用了<meta http-equiv="Content-Type" content="text/html" charset="UTF-8" />
,但还是不是我想要的...
问题: 服务器端字符错误。
非常感谢。
元标记无效...
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
这应该可以解决表单问题。
您也可以尝试使用表单 accept-charset 属性。
它是一个 JPA 并且 我在数据库上得到 "descri��o" 这个词,在我的服务器端调试中,就在持久性之前,当它从 Form 接收时,它就像 "descri��o" .
我有一个表单,<form action="..." method="post">
,它有一些字段并发送到 REST 服务,@post,我的断点就在其中并显示它。
我在表格HTML页面的头部使用了<meta http-equiv="Content-Type" content="text/html" charset="UTF-8" />
,但还是不是我想要的...
问题: 服务器端字符错误。
非常感谢。
元标记无效...
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
这应该可以解决表单问题。
您也可以尝试使用表单 accept-charset 属性。