Web Helpdesk - Counters
can add a counter to your page by adding the following line to your HTML document:
you have a virtual domain name, you must copy the script into your own cgi-bin
directory and change the tag so that the path to the counter script reflects
the path to your own cgi-bin directory.
will also need to make your HTML file
do this, you can type chmod
the UNIX prompt. Some FTP clients allow you to change permissions as well.
have put together an
examples of common SSI's you can use in your web pages. There's also a page
of example counters.
is a quick and simple solution for a counter, however it is important to note
that a hit counter is not a reliable way to track statistics on your web page.
Also, if you want control of your own count file, you will need to run a counter
from your own cgi-bin directory. We do not reset individual counters using
the above counter due to the number of other counters that would be affected.
Also, note that we do occassionally reset the entire counter in order to clear
up old counts for closed accounts, or with major webserver configuration changes.
is the procedure for setting up your own counter:
the following commands from the command line, in your public-web directory.
your own cgi-bin directory:
the permissions appropriately:
chmod 775 cgi-bin
the counter script to your own directory:
cp /home/www/cgi-bin/simplecounter.zip cgi-bin/
the permissions on the counter script:
chmod 775 counter.cgi
the permissions on the count file:
chmod 777 counter.txt
the counter script in an editor, you will need to edit several fields:
Change the path to the Perl interpreter, it should read:
Scroll down a bit and modify the path to the counter and the path to the images.
For instance, if your username was jetboy, these two lines would read:
the file and exit.
is how you would call the script from your HTML file:
you are calling the counter from another level other than the root of public-web,
you need to make the path in this include relative. In other words, if the
page that contains the include is at www.io.com/~user/subdirectory/whatever.html,
the counter tag should point to "../cgi-bin/counter.cgi".
counter is configurable, you can have it display a graphical odometer type
counter or a simple text counter. Read the
for more info.
you have a Virtual Domain Account you must complete two more steps
the GIF images out of your cgi-bin directory:
mv *.gif ../htdocs/
the path to the images in the script:
revised November 19, 1999