HTML and CSS Reference
In-Depth Information
Reviewing the Form
A completed form is shown in Figure 2-20 .
Figure 2-20. The completed feedback form
After entering values for each of the fields, click the Submit button and then view the page's source. Each
of the fields will now have a value attribute that contains the value that was included when the page was
submitted. This is what the server-side code would use to store and/or process the submitted data. I extracted
a portion of this, which is shown in Listing 2-3. I particularly want you to see how the various date/time field
values are formatted. Also notice that the color is stored as a hexadecimal representation of the selected RGB
values.
Listing 2-3. The source with submitted values
<li>
<label for="Birthday" id="lblBirthday">Birthday</label>
<input name="Birthday" type="date" value="2012-04-17" id="Birthday" />
</li>
<li>
<label for="Month" id="lblMonth">Favorite Month</label>
<input name="Month" type="month" value="2012-04" id="Month" />
</li>
 
Search WWH ::




Custom Search