CGI: Counter Script

You can put a counter on your Web page by following the directions below.

This script generates .xbm graphics. If the Web Browser cannot display .xbm graphics, the counter will not be seen.

Because the count generated by the counter script is only an approximation of the true count, we don’t recommend using this counter to keep track of the number of hits on your Web site. The script is only run when the image is retrieved.

  1. Log into the Unix commercial web administration tools and enable the cgi/ script for your website.
  2. Create an empty text file for the counter to store the count value in. This file can be called anything you want, but it's a good idea to call it something.val such as counter.val or index.val.
  3. Upload the counter.val file using FTP. Log in using the webmaster login and password.
  4. Use your FTP client to change the permissions on the counter.val file to 777. Most FTP programs will have an option called chmod or a selection of "UNIX commands." If you don't do this, the counter will not work.
  5. Add a link to the counter to your HTML code. You will need to use something like this: This page has been visited <img src=""> times.
  6. Replace the part that reads the-path-to-your-val-file with the actual path to your value file. If the counter file is in the Web-root directory, this will be docs/Vendors/wemasterlogin/html. For example: This page has been visited <img src=""> times.
    Don’t forget that this is case-sensitive.
  7. Load the Web page and you should see the counter!