Kioshi Help Page

Forms


Links to the good stuff:

Images * Tables * Basics * JavaScript

The Basics of Forms:

Forms are really just e-mail!
Those silly commands just format text.

Forms, at least at this stage of the game, are glorified e-mail messages. Sure, they can get complex, but right now we're discussing the simple feedback form. This section will focus on the Geocities style of form, since that plagues so many users.

Unlike normal e-mail, your form is not written entirely by the sender. Instead, you and the sender both contribute to the e-mail. You have a preset text, and the sender fills in the blanks.

To combine your text with the sender's text, the computer needs a "scratch" file to temporarily write down and merge the information. Since writing to the web server could allow someone to corrupt files, post nasty things, or upload a virus, access is limitted. The CGI-bin, a "safe", temporary area, is what is used as the scratch pad.

The <FORM> tags surround your form. Even if the form is the only thing on your page, many browser become "angry" if you do not use the closing </FORM> tag. Proper HTML helps your form work.

Like other tags <FORM> has attributes.

 

<form action="/cgi-bin/homestead/mail.pl?YourName" method="POST" name="Feedback">

is the standard geocities style. Attributes like ALIGN and NAME are optional, as are quotes ("), but you should use quotes (") to be absolutely sure.

For information, your form requires inputs. The <INPUT> tag is used for this. Attributes are very important to the <INPUT> tag. You do not use closing tags for <INPUT>.
Common attributes are:

TYPE This is required TEXT, HIDDEN, RADIO, CHECKBOX, SUBMIT, RESET
NAME This is required This identifies the field
SIZE This is usually specified number of characters in length and height
MAXLENGTH Optional This limits the number of characters accepted.

<input type="hidden" name="Subject" value="Web Site Comments">

This would be a pre-assigned value that your visitor doesn't see:


An example of TYPE="TEXT":

  Type three numbers
  with a MAXLENGTH

  Type three numbers (Do not hit return)
  and without the MAXLENGTH:

  Type several numbers (Do not hit return)
  without a MAXLENGTH but with a SIZE of only 3


This is a checkbox:

<INPUT TYPE="CHECKBOX" NAME="Check1">Please check here
Please check here

This is a preselected checkbox:

<INPUT TYPE="CHECKBOX" CHECKED NAME="Check2">
Automatically checked

 


These are RADIO buttons:

<INPUT TYPE="RADIO" NAME="Radio1" VALUE="A">A
<INPUT TYPE="RADIO" NAME="Radio1" VALUE="B">B
A   B

These are RADIO buttons with one selected:

<INPUT TYPE="RADIO" CHECKED NAME="Radio2" VALUE="A">A
<INPUT TYPE="RADIO" NAME="Radio2" VALUE="B">B
A   B

Notice, both choices have the same name. They return different values. Since they both have the same name, only one of the choices can be selected. If you want to use another set of radio buttons, use different names for each set.


Congratulations! You are now prepared to do some serious damage to the internet!





This Page Last Updated ,( Jan /),(

Copyright © 1997-1999 by Kioshi Ishitandai and Jason Caesar.

[GC] Pictures Captioned for the Graphically Impaired


1