• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jforum/admin,save Chinese incorrectly

 
xu yongqi
Greenhorn
Posts: 6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
when I use the functions of Admin,it can't save Chinese correctly.
for example:
url:jforum.page
action=editSave
module=adminCategories
category_name=中国

In jforum servlet,req.getParameter("category_name")="???",but when I use the functions of non-admin,such as createTopic,post,and so on,it can save Chinese correctly.

I think it might be related with 'enctype="multipart/form-data"'.If form has 'enctype="multipart/form-data"',it can save Chinese correctly,if it has not,save wrongly.

A few days ago,it all works well.I don't know why it fails now.
I have already set encoding=UTF-8.
 
xu yongqi
Greenhorn
Posts: 6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I find the cause.
I integrated jforum with cas.So I added cas filter in web.xml,then request.getParameter() of Chinese parameter got wrongly.
Then I added a characterEnocdingFilter in web.xml,it included request.setCharacterEncoding("UTF-8")
characterEnocdingFilter is the first filter,cas filter is second,then is jforum own filter.
Now it works all right.
I don't understand why I must add characterEnocdingFilter if I add cas filter.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic