jquery在加载页面后加载div [英] jquery load div after page load
本文介绍了jquery在加载页面后加载div的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
执行此操作的简单方法是什么?
< div id =container>
< div id =header>导航< / div>
< div id =bodyclass =body> Body< / div>
< div id =footer> footer< / div>
< / div>
解决方案
$(文档).ready(function(){
$ .get('ajax / page.php',function(data){
$('#body')。html(data) ;
});
});
Actually what I am looking for loading is loading the page first and then a div with lots of data. So, I want to load the main page first and then body div content using jQuery function with some delay.
What is the simple way of implementing this..?
<div id="container">
<div id="header">navigation</div>
<div id="body" class="body">Body</div>
<div id="footer">footer</div>
</div>
解决方案
$(document).ready(function(){
$.get('ajax/page.php', function(data) {
$('#body').html(data);
});
});
这篇关于jquery在加载页面后加载div的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文