var name = "Świat";
jQuery.ajax({
async: false,
contentType: "application/x-www-form-urlencoded;charset=UTF-8",
type: 'POST',
url: "test.do?name="+encodeURIComponent(name),
noCache:true,
data:{
},
beforeSend: function(xhr) {
xhr.setRequestHeader("Accept-Charset","UTF-8");
xhr.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");
...
in java i will have value like :
String pName = request.getParameter("name");
pName = "Å?wiat";
Now i want to search record from database using this name but in db has value with "Świat"
How can i find this or decode this ?