用户名:
密 码: 记住
您当前的位置:首页 > 网络编程 > 网站制作

iframe 的刷新方式 这样方式更方便

时间:1970-01-01  来源:互联网  作者:佚名
iframe的刷新方式

1. 刷新方式可以使用 javascript 的 document.fr.location.reload()

2. 还有就是修改 document.fr.location.href 也可以实现刷新的功能

例如:

复制代码代码如下:
<iframe name="fr" width="96%" src="alert_search.do?method=findSys"></iframe>
<script type="text/javascript">
function show_syslog(id){
document.fr.location.href="/alert_search.do?method=findSys&id="+id;
}
</script>
<input type="button" onclick="javascript:show_syslog(1)">

注意:千万不要两种方式同时使用,如果同时使用,将会提交两次。

复制代码代码如下:
document.fr.location.href = "your.html";
document.fr.location.reload();
来顶一下
返回首页
返回首页
推荐资讯
从零开始学ASP.NET-基础篇第1/7页 从零开始学ASP.NET-基础篇第1/7页第一天 学习目的: 掌握最基本的Label、TextBox、Button控件
ASP.NET入门数据篇 ASP.NET入门数据篇对于网站编程的初学者来说,总是会上网找些源码来看,但久而
相关文章
栏目更新
栏目热门