If you really want to become an XHTML table expert, take a look at
an article (and the pages linked to the article) called ???Bring on the
Tables??? on Roger Johansson??™s excellent 456 Berea Street site at http://
www.456bereastreet.com/archive/200410/bring_on_the_tables/.
Styling Forms
Forms are vital to most Web sites because they are the means by
which user-entered data can be sent from the browser across the
Internet to the site??™s Web server. From simple log-ins and sign-ups,
through to multi-page e-commerce checkouts, forms are everywhere,
and understanding how to create them is a key skill for every
Web developer. Because of their importance, I am going to start by
showing you in some detail how forms work and how their XHTML
is written before moving on to ways in which you can style them.
How Forms Work
The purpose of a form is to gather various pieces of data from the
user. When the form is submitted, usually by clicking a button, the
form data, structured as a set of name/value pairs, such as user_
name=tracey, is passed to the server to be processed by a server-side
script written in a language such as PHP, Java, or Perl. Even though
you might not be the person writing that server-side code, you need
Processing form data is outside of the
scope of this book, but if you want
to learn how forms send data to a
server, check if that data is valid (for
example , if e-mail addresses have
an @ in them), present any errors
back to user for correction and then
write validated data into a ?¬? le or a
database, check out my book, Codin??™
for the Web, also published by New
Riders.
Pages:
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228