JSP encoding while inserting non-English text in MySQL database

后端 未结 3 1727
被撕碎了的回忆
被撕碎了的回忆 2020-12-20 06:18

I am using Ajax call to insert Indian characters in MySQL database. I am facing an UTF-8 encoding problem in between flow of my application.

When I am inserting the

3条回答
  •  既然无缘
    2020-12-20 06:43

    One aside: Place the directives together without spaces. (You can even combine the attributes inside a single @page.) Because HTTP headers should be set before HTML content is written. Because of page buffering this is not strictly needed, but formally yes.

    The other answers till now are true.

    One additional issue is the database, table and field definitions which all can have a default and actual character set.

    Off course one should be really careful, મ��પ�ષ�ઠmight be a wrong display of the correct data, as the displaying program might not be using UTF-8.

提交回复
热议问题