Note that there are some explanatory texts on larger screens.

plurals
  1. POAgain! Spring MVC character encoding for POST method
    text
    copied!<p>I've already spent hours trying all possible solutions through out internet. Here is the problem: I need to have some Farsi inputs from user and save them in database. But as a result all I see is a bunch of <strong>question marks</strong>. Things I've tried so far:</p> <ul> <li>My database is utf8 encoded and so is my database connection</li> <li>I use encoding filters in my <em>web.xml</em> and also map it to all addresses. and place the filter on top.</li> <li>All my jsp pages have the appropriate <em>&lt;@page...></em> tag on top of them.</li> <li>Etc... But no luck. The point is if I omit the encoding filter I don't get question marks but some distorted characters instead. So I'm pretty sure that the filter is doing something.</li> </ul> <p>Do you have any guesses?</p> <p><strong>[edit]</strong> I'm sure it's not DB problem as well. since I can manually insert utf8 characters in my DB and read them by my application alright. I only have problem writing in DB.</p> <p><strong>[more details]</strong> suppose I want to add a name to a list. So I enter the string and post it. I then will be redirected to the list of the names with the new name appended and the name is all in question marks. If I enter a Farsi text right from the controller i.e in my java code I still have the problem. That's why I think it's not the filtering's fault. Since I can read utf8 characters from DB I'm pretty much confused where exactly is the source of problem. Controller part or DAO part?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload