View Customer Home pages
Guestbook

What is a guestbook?
How do I install the guestbook on my page?
What information is recorded?
Sample guestbook
What happens to information saved in the guestbook?
Additional information

What is a guestbook?

The guestbook CGI script allows you to offer a fill-in form on your home page. Visitors can enter their names, e-mail addresses and comments. Entries submitted to the guestbook are stored on another of your home pages. You can create up to five guestbooks. The choice of guestbook is controlled by the ?guestbook= n (where n is a number between 1 and 5, default is 1) parameter on the first line of the form tag.


How do I install the guestbook on my page?

You will need to create an HTML form on your home page where visitors can type in their names, e-mail addresses and comments. The following HTML can be copied and pasted into your home page to set up a guestbook:

<html>
<head>
<title>Guestbook CGI script</title>
</head>
<body>

<form method="post" action="http://www.btinternet.com/cgi-bin/guestbook/~xxxxxxxx?guestbook=1">
<input type="text" size="20" name="email">Enter your e-mail address here. <p>
<input type="text" size="20" name="name">Enter your name here. <p>
<textarea name="comments" rows="6" cols="20"></textarea>Enter your message here. <p>
<input type="hidden" name="usertitle1" value="Tailor Field One">
<input type="hidden" name="usertitle2" value="Tailor Field Two">
<input type="hidden" name="usertitle3" value="Tailor Field Three">
<input type="hidden" name="usertitle4" value="Tailor Field Four">
<input type="text" size="20" name="userfield1">Enter info in first user configurable field here<p>
<input type="text" size="20" name="userfield2">Enter info in second user configurable field here <p>
<input type="text" size="20" name="userfield3">Enter info in third user configurable field here <p>
<input type="text" size="20" name="userfield4">Enter info in fourth user configurable field here<p>
<input type="hidden" name="nextpage" value="/~xxxxxxxx/thanks1.htm">
<p><input type="submit" name="B1" value="Submit">Click here to send your message </p>
</form>

</body>
</html>

You need to replace the xxxxxxxx with the e-mail name used for your home page. Of course you can modify the layout of this form. Note that you should keep the HTML in lower case only. If you use capital letters, the Guestbook will not work correctly.

The line:

<input type="hidden" name="nextpage" value="/~xxxxxxxx/thanks1.htm">

is optional but enables you to design your own page thanking the visitor for leaving a message. It also enables you to provide onward links from the page. A link to display the Guestbook and to your homepage would be worth while.


What information is recorded?

  • Visitor's name (entered via a text box on the HTML form calling the Guestbook). The maximum length of this field is 80 characters. If the visitor enters a longer name than this it will be truncated.
  • Visitor's e-mail address saved as a mailto: link (entered via a text box on the HTML form calling the Guestbook) The maximum length of this field is 80 characters. If the visitor enters a longer name than this it will be truncated.
  • Date and time that the Guestbook entry was appended. The format of this field is "Day, Month DayNumber, Year, Time".
  • Visitor's IP address (stored as hidden HTML in the Guestbook) to allow the tracing of malicious postings. The IP address will be found from the REMOTE_ADDR HTTP environment variable. If it is not available, a message to that effect is appended to the Guestbook in its place.
  • Comments made by the visitor to the Guestbook. The maximum length of this field is 820 characters. If the visitor enters a longer comment than this it will be truncated.
  • User Configurable fields 1-4 There are four extra fields which may be specified to gather extra information from your visitors. The maximum length of these fields is 80 characters.

Sample Guestbook

You can see a working example of the Guestbook.


What happens to information saved in the Guestbook?

When a visitor to your site clicks the Submit button on the Guestbook form, a new entry is appended to the selected Guestbook. Information is stored in your home page directory (pub) in an HTML page called guestbookfilen.html (where n is a number between 1 and 5, corresponding to the Guestbook you have chosen). You can link to this file if you want others to see comments in your Guestbook, or edit this file in terms of its layout or to delete unwanted entries.


Additional information

Guestbook fields entered in the user form will be truncated if necessary to ensure that they fit within the limits specified above.

If any fields are missing from the form page that submits the information to the Guestbook, the relevant information in that entry is left blank.

Extra fields passed to the HTML form are ignored.

The order of the input objects in the HTML does not affect the correct operation of the Guestbook.

The Guestbook replaces any < or > characters with their equivalent control codes in HTML. This means that they display correctly in the Guestbook file.

A record will not be added to the Guestbook if it will cause you to overflow your quota of disk space. An e-mail will be sent to you the first time a Guestbook record cannot be added because the disk quota has been reached. The e-mail will alert you that your Guestbook is full and will advise you how to rectify the situation. Subsequent attempts to add to your Guestbook record will not cause further e-mail to be sent.

About us - Contact us - Disclaimer - Terms & conditions - Privacy statement - Advertise on BTinternet - Site map
Copyright © 2000 British Telecommunications plc