Hi,

I have the following servlet that returns:
....
 response.setContentType("text/plain;charset=UTF-8");
 out.write("{\"XXX\":1}");
...

My Html is

$(document).ready(function(){

   $.getJSON("http://localhost:8080/getData";,
      function(json){
         alert("getJSON Server Data->"+json);
        });

   $("input.dataUpdate").click(function () {
                $.ajax({
                        url: "http://localhost:8080/getData";,
                        success: function(data) {
                           alert('ajax Data->'+data);
                        }
                });
        });
});


Here the $.ajax() does not work neither in Mozilla nor Chrome, but it
works in IE

Can you help me

Thanks in Advance

Reply via email to