I use the Google Places Autocomplete api for a web application that is going to have accented characters as input.
I am trying to strip accents from the input strings so that the Google Places Autocomplete can work properly.
When I type the following string sévin in the browser, I get the following in my IDE:

Then, of course, instead of getting the following unaccented string: sevin, I get something like: sA©vin.
I have no clue in which layer of my app, the encoding issue occurs.
Here is the JQuery/JS:
ajax : {
url : base + '/geolocation/addressAutocomplete',
dataType : 'json',
data : function(term) {
return {
address: term
};
},
results : function(data) {
if (data.status == 'OK') {
return {
results : $.map(data.predictions, function(item) {
return {
id : item.reference,
text : item.description
};
})
};
}
}
},
Here is the Spring MVC controller method:
@RequestMapping(value = "/addressAutocomplete", method = RequestMethod.GET, produces = "application/json")
@ResponseBody
public GooglePlacesAutocompleteResponse validateAddressAutocomplete(@RequestParam String address) {
return geolocationService.autocompleteAddress(address);
}
Can anyone please help?