jQuery的AJAX获取HTML数据IE8不工作 [英] jQuery AJAX GET html data IE8 not working
本文介绍了jQuery的AJAX获取HTML数据IE8不工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
这是在code,但它不工作在IE8和放大器; 7(IE9,Chrome浏览器,火狐,Safari,歌剧都是OK)。我已经尝试了很多东西(元UTF-8 code,PHP头code,采取警示,缓存:假的)。什么能做些什么,我需要帮助。感谢您的利益。
VAR请求= $阿贾克斯({
键入:GET,
网址:_veri.php T = icerik_getir和ID =?+ tabopen,
数据类型:HTML,
});
request.done(函数(MSG){
$(制表contentmenu。)HTML(MSG)。
});
编辑:
警报给我的要求在所有的浏览器,但仍然没有在.TAB-contentmenu请求数据的数据,我应该怎么办?
VAR请求= $阿贾克斯({
键入:GET,
背景:document.body的,
网址:_veri.php T = icerik_getir和ID =?+ tabopen,
数据类型:HTML
});
request.done(函数(MSG){
$(制表contentmenu。)HTML(MSG)。
警报(味精);
});
解决方案
我解决了这个问题,在PHP文件中有一个未关闭的股利和我删除它。
This is the code but it's not working on IE8 & 7 (IE9 , chrome,firefox, safari,opera are all ok). I have tried a lot of things (meta utf-8 code, php header code, taking alerts, cache:false).What can i do , i need help. Thanks for your interests.
var request = $.ajax({
type:"GET",
url: "_veri.php?t=icerik_getir&id="+tabopen,
dataType: "html",
});
request.done(function(msg) {
$(".tab-contentmenu").html(msg);
});
EDIT:
alert gives me the data of requested in all browsers but still no requested data in ".tab-contentmenu" , what should i do?
var request = $.ajax({
type:"GET",
context: document.body,
url: "_veri.php?t=icerik_getir&id="+tabopen,
dataType: "html"
});
request.done(function(msg) {
$(".tab-contentmenu").html(msg);
alert(msg);
});
解决方案
I solved the problem , in php file there was a unclosed div and I removed it.
这篇关于jQuery的AJAX获取HTML数据IE8不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文