使用onclick/表单submit跳转到其他页面

使用onclick

如果是本页显示可以直接用location,方法如下:

- onclick="javascript:window.location.href='URL'"
 - onclick="location='URL'"
 - onclick="window.location.href='URL?id=11'"

如果页面中有frame可以将在location前面添加top.mainframe.frames[‘right_frame’].location


使用submit

使用form表单创建一个只有submit按钮的表单,单击提交即可

<form action="URL" name="表单名" method="get">
	<table><td colspan="2"><input type="submit" value="注册"></td></table>--%>
 </form>
posted @ 2019-05-28 11:25  jirath  阅读(1820)  评论(0编辑  收藏  举报