where XXX is the name of your site. (i.e. if your URL is
http://www.InstantWeb.com/D/dolphin then your site
name is dolphin), and X is the first letter of your site name
as in d for dolphin.
the_name_of_your_script is your scripts name, like information.pl.
2. The next step is to write the CGI script that will do something with the information passed to it from your form. This script can be written in Perl, C or as a shell script. For help with writing scripts, please refer to Instant Web Sites World Wide Help, CGI Scripts and Forms.
3. Once you get your form designed, and have written the script for it, you need to know how to hook it up on our system.
In your home directory you will find a directory called cgi-bin. (Your home directory is where you are when you first FTP in to your account.) Place all of your CGI scripts in this directory.
4. Make sure that the filename of your CGI script ends in .cgi (for C or shell scripts) or .pl (for perl scripts).
5. On Unix systems (which is the system that InfoStreet runs on), script files must be executable before you can run them. Using your FTP software, change the permissions of the CGI script file to be executable. This can be done with the following command:
or alterantively, you can use the Make Executable tool to change the permission of your CGI script file to be executable. This is a MUST. Your CGI scripts will not run unless they have executable permission.
6. The last step is to tell your form, where the script is that it is supposed to execute. Tell the html document calling the script that the path name to execute the script is,
where XXX is the name of your site. (i.e. if your URL is
http://www.InstantWeb.com/D/dolphin then your site
name is dolphin), and X is the first letter of your site name
as in d for dolphin.
the_name_of_your_script is your scripts name, like information.pl.
For Example
Suppose that you wrote a form called information.html that asked for information about your users. Then you wrote a CGI script called information.pl (lets make it a perl script) to collect that information. Next you made sure the script worked, placed it in your cgi-bin directory, and made it executable. Now you want to place a line in the HTML form information.html to call the CGI script information.pl. To do this, you need to know your site name. Lets assume for this example it is dolphin.
If you are using the POST method in your information.html form, you would need to use the following line.
The above line tells the form to execute the script information.pl, in the directory /d/dolphin/cgi-bin. Or in other words, execute the script that is in your cgi-bin directory.
Instant Web Sites are a service of InfoStreet Inc.