I m working on site and it has a fram. think of the gmail frame. And much like the gmail app I want only the inner div to be updated when clicking links on the navbar. I ve got it so the div changes, but it certainly does not give me the results I m hoping for. this is a rough outline of what I have
<div id=container>
<div id=page>
... some child divs in here
</div></div>
由于该集装箱有固定的滚动条,我不想改变我只希望更换一页。 这是我设法在支部上走的。 我只是一个开端人,所以我不知道我做些什么,但我不想学习。
$(document).ready(function () {
$.ajaxSetup ({
cache: false
});
var ajax_load = "<img src= bin/pics/loading.gif alt= loading… width= 32px height= 32px style= top: 250px; left: 250px; />";
var loadUrl = "bin/ajax/load.html";
$("#mybuton").click(function(){
$("#page").load(loadUrl);
location.hash = ajax ;
});
});
the load html contains this
<link rel="stylesheet" type="text/css" href="bin/main.css" />
<div id="page">
<div id="child">
<h1> sometitle </h1>
</div>
</div>
任何建议?