Read Web Standards Solutions, Chapter 5: Forms.
Download and tinker with the code examples in chapter5.html. Open it in your browser. What effect does the type attribute have on the markup? Can you change the form styling to customize your form?
Forms are how we send information to the server. What is a server? When you go to a website, what you’re actually doing is talking to another computer out in the world somewhere. The website’s URL is like an address for that computer. In developer-speak your computer is called the Client, and the computer whose address you are visiting is called the Server. Our client can send information to the server. The server can then do things with that information, like serving up a custom page.
Be ready to answer the following questions during Q/A next week
- The
<input />element is used to create a form field that lets the user pass data to the server. What is the effect of thetypeattribute on input elements? - What are some of the benefits of using the
<label>tag in a form? - What is the HTML tag for grouping a set of form fields?
Beware: There is a typo in the code example on pg 64. The code reads <divlabel for.... It should read <div><label for....