Forms
Connect labels to inputs, use appropriate types, and leverage built-in validation.
Try it
<form onsubmit="alert('Submitted!'); return false;">
<div>
<label for="email">Email</label>
<input id="email" name="email" type="email" required placeholder="you@example.com">
</div>
<div>
<label>
<input type="checkbox" name="agree" required> I agree to the terms
</label>
</div>
<button type="submit">Submit</button>
</form>