I've been struggling with this one for some time. I have this code:
<h2 id="registerH2">Subscribe to the cake club.<br>
Please fill out the form. (* means required)</h2>
<div id="subscribeBox">
<form class="subscribeForm" name="Subscription Form"><br>
<input Name="First Name" type="text" required id="fname" placeholder="First Name*"><br><br>
<input id="lname" type="text" placeholder="Last Name*" name="Last Name" required><br><br>
<input id="email" type="email" placeholder="Email*" name="Email" required><br><br>
<input id="address" type="text" placeholder="Address (optional)" name="Address"><br><br>
<input id="submit" type="submit" value="Send" onclick="href=registered.html">
</form>
</div>
So what I want to do is when I click the "send" button in my website, to direct me to another html file I have. Right now it's not working with this code.
(This is for my assignment I'm not working on a cake club :D)
What your want is a action="registered.html"
attribute in your form
In any form when you hit a submit
type input
<form action="registered.html"> [...] </form>
is triggered
read more on w3school https://www.w3schools.com/tags/att_form_action.asp
Cheers.