I have got a PHP script (CMS) which generates ISO-8859-1 content (in the background there is also a database with Latin1 data). To visualize the data on mobile devices I use
The problem is that jQuery Mobile 1.3.1 uses on default UTF-8 on ajax requests. There are different solutions to solve the problem:
Disable Ajax for specific links, which redirect to content with special characters:
data-ajax="false"
Turn off completely the ajax preloading feature:
$.mobile.ajaxEnabled = false;
Follow this recommendation and manually set the correct content type and override the mime type:
$.ajaxSetup({
contentType: 'application/x-www-form-urlencoded; charset=ISO-8859-1',
beforeSend: function(jqXHR) {
jqXHR.overrideMimeType('application/x-www-form-urlencoded; charset=ISO-8859-1');
}
});
The last solution did work for me.