`
韶音韶乐
  • 浏览: 84797 次
  • 性别: Icon_minigender_1
  • 来自: 太原
社区版块
存档分类
最新评论

HTML中添加后退、前进、刷新的超链接

阅读更多

<!--
<a href='javascript:history.go(-1)'>后退</a>
<input name='ht' type='button' onclick='javascript:history.go(-1)' value='后退' />
-->

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>后退前进刷新</title>

<script language="javascript">
function next()
{
document.write("<a href='javascript:history.go(-1)'>后退</a>   &nbsp;&nbsp;<a href='javascript:history.go(0)'>刷新</a>&nbsp;&nbsp;<a href='javascript:history.go(1)'>前进</a>   <form>   <input name='ht' type='button' onclick='javascript:history.go(-1)' value='后退' />   <input name='sx' type='button' onclick='javascript:history.go(0)' value='刷新' />   <input name='qj' type='button' onclick='javascript:history.go(1)' value='前进' />   </form> ");
}
</script>
</head>

<body>
<a href="#" onclick="next()">跳到下一页</a>
</body>
</html>

<script></script>
分享到:
评论
1 楼 lliiqiang 2015-08-07  
逻辑增加的时候,最好增加一个标志位表示最终增加的id表示实际成功增加的顺序.

相关推荐

Global site tag (gtag.js) - Google Analytics