简体   繁体   English

Jquery.load()在Firefox中不起作用

[英]Jquery.load() not working in Firefox

I am having a very odd problem with jQuery .load(). 我在使用jQuery .load()时遇到了一个非常奇怪的问题。 The code below is woking fine in Safari but is delivering null value data in FireFox. 下面的代码在Safari中可以正常运行,但是在FireFox中提供了空值数据。 However, when I check the response it is saying success . 但是,当我检查响应时,它表示成功

$.ajaxSetup({cache:false}) ;
$(document).keydown(function(e) {
    if (e.keyCode == 27 && $("#MasterEditHelper").val() == 1)   {
        var No = $("#MasterEdit").attr("value");
        var Id = "#Box-"+No;
        var viewType = $('#ViewType').val();
        $(Id).html('<p class="updating">UPDATING</p>');

        $(Id).load("/Styles/Zoom/Update", {id : No, view : viewType});


        $("#MasterEdit").css('display' , 'none');       
        $("#MasterEditHelper").val(0);
        $("#sub-duvet").fadeIn();
        } 
});

Does anyone know why this is happening? 有人知道为什么会这样吗?

Could you check this out: http://jsfiddle.net/kVdXZ/3/ 您能否检查一下: http : //jsfiddle.net/kVdXZ/3/

Tried recreating your script, and it seems to be working fine in firefox and others. 尝试重新创建脚本,并且在Firefox和其他程序中似乎运行良好。

So it seems it's your URL that might be causing the problems? 看来是您的URL可能引起了问题?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM