Jump to content

[SOLVED] IE and AJAX ResponseText


jackpf

Recommended Posts

Good evening all,

I'm implementing a new AJAX post system for my forum, and updating the content to show the new post by reloading the body. Eg,

document.getElementsByTagName('body')[0].innerHTML = ajax.responseText;

 

This works fine in all browsers except IE, which refuses to reload the body. I've tried updating the body to something else, like

document.getElementsByTagName('body')[0].innerHTML = 'IE sucks';

And it works fine, so I think it's something to do with the AJAX part.

 

I was just wondering if anyone else has experienced the same problem, or knows how to get around it?

 

Cheers,

Jack.

Link to comment
https://forums.phpfreaks.com/topic/157606-solved-ie-and-ajax-responsetext/
Share on other sites

I think it might be something to do with the fact that I'm sending a header back...

I don't think IE can understand it. I currently use error catching to hide all the stupid errors IE thinks exist, but I removed it, and got a "c00ce56e" error on the line that updates the body.

 

Yeah, have you ever had a problem with headers, AJAX and IE? :P

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.