Complete the code to create a form element.
<[1] action="/submit" method="post"> <label for="name">Name:</label> <input type="text" id="name" name="name"> </[1]>
The form tag defines a form in HTML. It groups input elements and allows data submission.
Complete the code to add a submit button inside the form.
<form action="/submit" method="post"> <input type="text" name="email" aria-label="Email address"> <button type="[1]">Send</button> </form>
type="button" which does not submit the form.type="reset" which clears the form inputs.The submit type on a button sends the form data to the server when clicked.
Fix the error in the input field to make it accessible by linking label and input.
<label for="[1]">Username:</label> <input type="text" id="username" name="username">
for and input's id.id attribute on the input.The for attribute in the label must match the id of the input to connect them for accessibility.
Fill both blanks to create a text input with a placeholder and required attribute.
<input type="[1]" name="email" placeholder="[2]" required>
email type but placeholder says 'Enter your name'.The input type should be text for general text input. The placeholder shows a hint inside the input box.
Fill all three blanks to create a form with a label, input, and submit button.
<form action="[1]" method="[2]"> <label for="user">[3]</label> <input type="text" id="user" name="user"> <button type="submit">Send</button> </form>
get method when post is expected.The action attribute sets the URL to send data. The method is usually post for sending data securely. The label text describes the input.