单击按钮重定向到另一个页面 [英] Redirect to another page with button click
本文介绍了单击按钮重定向到另一个页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何获得一个按钮来打开另一个页面 - 我有这个
< button type =" button"> Buggy Whipp Bio< / button>
i需要它将用户带到越野车whipp bio.html
任何帮助将不胜感激
how do I get a button to open another page - I have this
<button type="button">Buggy Whipp Bio</button>
i need it to bring a user to buggy whipp bio.html
Any help would be appreciated
推荐答案
如果你想避免使用JavaScript,那么使用提交按钮并将动作设置为你想要重定向到的页面:
If you want to avoid JavaScript, then use a submit button and set the action to the page you want to redirect to:
展开 | 选择 | 换行 | 行号
嘿这样做onclick =" location.href =''your_redirectio npage.html''"享受
Hey do this onclick="location.href=''your_redirectionpage.html'' " enjoy
是的,这将是重定向到另一个页面的JavaScript方法。
你也可以使用按钮标签作为提交按钮指定type =" submit"。
Yes, that would be the JavaScript method of redirecting to another page.
You can also use the button tag as a submit button by specifying type="submit".
这篇关于单击按钮重定向到另一个页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文