<p>This is just a typical form with an awful color scheme to easily show our purpose.</p>
<form id="form1" action="">
<label id="firstName">First Name: <input type="text" /></label>
<label id="email">Email Address: <input type="text" /></label>
</form>
<p>What we've done is wrapped the inputs with their labels and then applied some styles to those labels. In this way you can click anywhere within the green area to put focus on that input. It even allows for some hover action on the labels as well. In some cases this is much easier to accomplish than clicking inside the input for focus, especially mobile devices. Simply put, the label becomes more like a button.</p>
<p>There are other useful things we can do with this method.</p>
<p>Say we have a form like this:</p>
<form id="form2" action="">
Check1: <input type="checkbox" />
Check2: <input type="checkbox" />
Check3: <input type="checkbox" />
</form>
<p>You'll notice that it is required to click on a checkbox itself to get it checked.</p>
<p>Using labels as containers we can use CSS to position the checkboxes where we want inside the form.</p>
<form id="form3" action="">
<label id="check1">Check1: <input type="checkbox" /></label>
<label id="check2">Check2: <input type="checkbox" /></label>
<label id="check3">Check3: <input type="checkbox" /></label>
</form>
<p>And again, each one of those labels acts as a button for the checkbox. This time we put a pointer cursor on there to make even more like a clickable button.</p>