无ajax 局部刷新功能嵌套窗口,子窗口更改父窗口内容
<div id="content2" style="width: auto;display: ${bundleJudgeInfo.gradeMethod==3 ? 'none' : 'block'}">
<h1>
评分项
<button class="tabM" id="spanOne" onclick="Tabset.showdt(this,1);">录入评分项</button>
<button class="tabM" id="spanTwo" onclick="Tabset.showdt(this,2);">上传评分项</button>
</h1>
<div id="ingredientDiv" >
--更改这里的内容
</div>
<div id="secondDiv" style="width: auto; display: 'none';">
<IFRAME id="iframe1" src="/evaluate/bundleExcel.do?method=gradeIngredFile&id=${bundleEvaluate.id}"
style="border: 0px; width: 100%; height: auto;" frameborder="0" scrolling="auto"></IFRAME>
</div>
大家好,这个代码不生效。何解?
//数据初始化
function dataInit() {
var pDiv = window.parent.$('gradeIngredientTable');
pDiv.innerHTML=$('gradeFile').innerHTML;
}
嵌套窗口赋值:
//数据初始化
function dataInit() {
var pDiv = window.parent.document.getElementById('ingredientDiv');
pDiv.innerHTML = $('tableDiv').innerHTML;
}