开发者

jQuery $.get/$.post, IE don't display everything

开发者 https://www.devze.com 2023-04-11 17:21 出处:网络
I do some get/post action in my jquery code which return some html code. This html code is usualy one or two div\'s with some long text in it. It work fine in FF or Chrome, but in IE (7/8) it only dis

I do some get/post action in my jquery code which return some html code. This html code is usualy one or two div's with some long text in it. It work fine in FF or Chrome, but in IE (7/8) it only display first div without the second one. I spend 3 days on it, but I didn't find any solution :-(

Thank you for any help

EDIT:

some code:

$.post("http://www.xxx.pl/xxx/get_xxx.php?hash=<?php echo md开发者_如何学Go5(time());?>&OBJW="+$(this).attr("id_objw"),function(data3){
                                            $("#LEK").html(data3);
                            });


I had similar problems few months back and it was about malformed html markup. the html returned by server had unclosed tags. Correcting html markup that is returned by ajax call solved the problem for me.


IE has a built-in debugger (if you have not anything else) use it to see what's there in result. Check for some server errors, check the type you're using in get/post


Maybe you should tell the browser not to cache the result. IE's caching mechanism works different from other browsers. Try

$.ajaxSetup({cache: false});

However, this has no effect on post(), it only affects get()

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号