Share this Page URL

Chapter 12. Need Feedback? Create a Form! > Creating a Form - Pg. 129

Need Feedback? Create a Form! 129 Figure 12.1. A form used for searching. Of course, there are lots of possible uses for forms. If you put out a newsletter or magazine, you can use forms to gather information from subscribers. If your website includes pages with restricted access, you can use a form to get a person's user name and password for verification. If you have information in a database, you can use a form to have people specify what type of information they want to access. Creating a Form You create forms using special HTML tags, and it's pretty easy to set up a form. To get started, enter the <FORM> and </FORM> tags. These tags can be inserted anywhere inside the body of the page. You place all the other form-related tags (which I show you in the rest of this chapter) between <FORM> and </FORM>. Page Pitfalls Creating a form is fairly easy, but getting your mitts on the information that the reader types into the form is another matter. The problem is that this requires some programming, so it's well beyond the scope of a humble book such as this. So what's a poor, programming-challenged web wizard to do? Check out the section titled "Oh say, can you CGI?" later in this chapter. The <FORM> tag always includes a couple of extra goodies that tell the web server how to process the form. Here's the general format: <FORM ACTION="url" METHOD="METHOD"> </FORM>