今天用jquery中的ajax替换掉以前的ajax程序
发现ie很多时候都加载不上(空的) firefox可以正常加在
怀疑是ie下加载时间过长而导致错误 里面加载了个discuz模板 还有大片的mysql查询这是我ajax程序 老鸟帮我优化优化 先谢谢了 $.ajax(
{
type:"POST",
url:that.url_str,//url 地址
data:that.str, //发送的数据
success:function(html)
{
$('#'+that.div_id).html(html);
document.getElementById("newDrag").style.display="block";
document.getElementById(that.div_id).style.display='block';
that.func_name(that.paratmeter);//回调函数
that.func_name_other(that.parameter_other);
}
发现ie很多时候都加载不上(空的) firefox可以正常加在
怀疑是ie下加载时间过长而导致错误 里面加载了个discuz模板 还有大片的mysql查询这是我ajax程序 老鸟帮我优化优化 先谢谢了 $.ajax(
{
type:"POST",
url:that.url_str,//url 地址
data:that.str, //发送的数据
success:function(html)
{
$('#'+that.div_id).html(html);
document.getElementById("newDrag").style.display="block";
document.getElementById(that.div_id).style.display='block';
that.func_name(that.paratmeter);//回调函数
that.func_name_other(that.parameter_other);
}
{
type:"POST",
url:that.url_str,//url 地址
data:that.str, //发送的数据
success:function(html)
{
$('#'+that.div_id).html(html);
$('#newDrag').show();
$('#'+that.div_id).show();
that.func_name(that.paratmeter);//回调函数
that.func_name_other(that.parameter_other);
} 你回调函数都没有加载 就 $('#'+that.div_id).html(html);
$('#newDrag').show();
$('#'+that.div_id).show(); 吧这3个放到回调函数出来。 alert一下是什么地方出的问题,应该是还没有加载玩你就先赋值了。