| > > > |
Count.cgi
Example:
<form method=post action="/g-cgi-bin/gbook.cgi">
<br>
Name: <input type=text name="name" size=25>
<br>
EMail: <input type=text name="email" size=20>
<br>
Web Site: <input type=text name="www" size=25 value="http://">
<br>
Comment: <br><textarea name="comment" cols=50 rows=10 height=30 length=70></textarea>
<br>
<input type=submit value="Sign Book"><input type=reset value="Reset">
</form>
Description:
gbook.cgi is an easy to implement Guestbook program based on a script by Kevin Meltzer.
The program accepts four variables passed to it via the <form> tag. Please see the example above.
After the user enters his or her information, the program will save the data in a data file called "guestbook.dat".
This file is stored in the "~/public_html/CGI_Data/Guestbook/" directory.
Once the program saves the information to the "guestbook.dat" file, it then displays a generic "thank you" message.
You may customize this "thank you" page if you wish.
Simply save the customized page as "thanks.html" in the "~/public_html/CGI_Data/Guestbook/" directory.
Frequently Asked Questions:
1. How do I display the contents of the "guestbook.dat" file on my page?
The easiest way is to use "Server Side Includes". Simply add the following line to the end of
your guestbook page _before_ the </body> tag:
<!--#include virtual="/CGI_Data/Guestbook/guestbook.dat"-->
Please note that in order for Server Side Includes to work, your HTML file must be saved with
the ".shtml" extension. For example, instead of calling your guestbook page "guestbook.html",
it would be called "guestbook.shtml".
Additional Documentation:
Guestbook Home Page
|
|