views:

30

answers:

2

The trouble is that everything works fine on every browser except IE. I get content from xml and I am able to print it, but on IE it gives empty.

After some googling the problem might be width this header("content-type:application/xml;charset=utf-8"); Where am I suppoesed to put that? On the xml file start or?

Thanks.

A: 

In Javascript:

  var req = new XMLHttpRequest();
  req.open("POST", "http://www.example.com/", true);
  req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");

Check the JQuery XHR documentation for a similar API.

jeffamaphone
A: 
$.ajax({
    'url': '',
    'beforeSend': function(xhr) {
        xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
    }
});

also try to disable ie cache with php

header("Cache-Control: no-cache, must-revalidate"); header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); header("Pragma: no-cache");

Quji