假设abc()这个是iframe中的函数,同时这个函数操作的是iframe页面中的内容
art()是当前父页面的函数,那么应该怎样在art()中运行iframe中的这个abc(),//iframe页 load.html
functon abc(){
.............
}//当前页面
<iframe src=/load.html
function art(){
该怎样执行abc()使之操作load.html页面中的内容
}
art()是当前父页面的函数,那么应该怎样在art()中运行iframe中的这个abc(),//iframe页 load.html
functon abc(){
.............
}//当前页面
<iframe src=/load.html
function art(){
该怎样执行abc()使之操作load.html页面中的内容
}
<script>
function callChildFrame() {
load.abc();
}
</script>
<input type="button" value="callChild" onclick="callChildFrame()" />
<hr />
<div>
<iframe name="load" src="load.htm" />
</div>
iframe子页面load.htm脚本
<script>
window.abc = function abc() {
alert('this is the function abc in iframe load');
}
</script>
this is load.htm
document都写错了还能加10分!