![]() |
In the previous section we looked at the code needed to place a form on your web page. But the big question is how do
you get to the data once the user has filled in the form? Strictly speaking, the best way is to use a CGI (Common
Gateway Interface) script, probably written in a language such as Perl, contained in the cgi-bin folder of your
server. However, unless you run your own server you probably don't have access to that folder -- most ISPs are
very wary about letting strangers wander around cgi-bin!
To make up for this, most ISPs provide a few scripts which any subscriber can use, and many of them allow you to create
your own form to use with the scripts. In this case, your ISP will be able to tell you how to get access to the script. It
will probably mean putting something like this is your <FORM> tag:
<FORM ACTION="http://isp.com/cgi-bin/form.cgi" METHOD=POST>
Usually the script will take the data from the form and put it into an e-mail which will then be sent to you, so somewhere
(probably in a Hidden element) you will have to include your e-mail address. Here is an example of a form provided by a
service provider (it's been adapated so please don't try and use it, because it won't work!):
<FORM ACTION="/user-cgi/FormMail.pl" METHOD=GET>
The form looks like this:
If your ISP doesn't provide any scripts for you to use, all is still not lost. There are a number of places on the World Wide
Web which will provide this service free of charge. One I've used myself is FreeForm (URL: http://www.note.com/success/public/freeform). The
form below is one of theirs and it does work -- try it out and I will e-mail back to you a copy of the e-mail I
receive from FreeForm (REMEMBER: you must put your e-mail address if you want me to do this!):
Now you've got your forms all sorted out, you are ready to go on to the last stage of the tutorial, Framing Your Site. ![]()
|
![]() |
||
|
![]() Minor revisions: 16 May 1998 at 23:17 {{GMT}} |
a member of ![]() |