[英]How to link to another html page with one button?
I am able to have another html page appear when clicking "register" but it is currently separate from the "register" button that I had originally created. 单击“注册”时,我可以显示另一个html页面,但它目前与我最初创建的“注册”按钮分开。 The href sits right beside the button created and unable to find a way to make it sit inside the button.
href位于创建的按钮旁边,无法找到使其位于按钮内部的方法。 Is there another way to do this to have it work inside the button?
还有另一种方法可以使它在按钮中起作用吗?
I've tried adding the Register which works inside of the button that I created but it did not work, the button breaks 我尝试添加可在我创建的按钮内使用的寄存器,但该按钮不起作用,按钮断开
<a class="btn" href="Register.html"> Register</a>
<button
type="submit"
class="btn btn-secondary btn-block"
id="registerLink"
></button>
Working on a "Log in" form. 使用“登录”表单。 On the click of the register button the register form I had completed previously should appear.
单击注册按钮后,应显示我之前填写的注册表格。 I am trying to get back 1 single button in my class="btn btn-secondary btn-block" button.
我想找回我的class =“ btn btn-secondary btn-block”按钮中的1个按钮。
You have two buttons. 您有两个按钮。 One of them doesn't have a closing tag.
其中一个没有结束标签。 That's going to result in unpredictable behavior.
这将导致不可预测的行为。 I am not sure I fully understand your question.
我不确定我是否完全理解您的问题。
Add the same classes to the link that you have added to the button and it should now look like a button instead of a link. 将相同的类添加到已添加到按钮的链接中,它现在看起来应该像按钮而不是链接。
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous"> <a href="Register.html" class="btn btn-secondary btn-block"> Register</a>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.