Home > Back-end >  Struts 2 hibernate web project with mysql link character set wrong, ask for help!!!!!!!!!!!!!!!
Struts 2 hibernate web project with mysql link character set wrong, ask for help!!!!!!!!!!!!!!!

Time:12-16

Basic can change all the places have changed, or noise, not even directly within the mysql insert,
According to


MySQL: version 5.1
My. Ini file


In mysql code shows:




Myeclipse: version 8.5
Hibernate. CFG. Within the XML:


The JSP to add data:


In mysql data show:

CodePudding user response:

Save the children!

CodePudding user response:


You look at is the cause of the editor, as a result of the code

CodePudding user response:

I see, is not a myeclipse problem, is a question of mysql character set

CodePudding user response:

Show the code after hibernate to mysql, but according to normal after returned from mysql JSP,

CodePudding user response:

On the hibernate configuration data address any charaterEncoding=utf-8

CodePudding user response:

ServerTimezone=UTC& UseUnicode=true& CharaterEncoding=utf-8 & amp; UseSSL=false

CodePudding user response:

reference 5 floor liuting52001 reply:
on the hibernate configuration data address any charaterEncoding=utf-8

added
  • Related