|
Server Side Include Counter
Chapter 3-4-4 ROCKCI
DIY Virtual Server Features Server
Side Include Counter
A server side include type counter script has been included in your
cgi-bin directory. This is a very simple text type counter. It has some
advantages over the typical www.digits.com
graphical type counter used on a lot of pages on the web.
WWW user doesn't have to wait forever to get a reply from www.digits.com
WWW user will never see the word BUSY instead of a count.
You won't loose counts because user didn't wait for a reply from digits.
Counter is text and doesn't take time to load like graphical counters.
To use the server side include counter installed in your cgi-bin directory:
1. Add the following to your home page html where the count
should appear:
<!--#exec cgi="/cgi-bin/counter.cgi"-->
2. Change the filename extension to .shtml (ie. index.shtml
)
3. Counter works.
Note: the counter has the following options:
| -nd |
won't display just count |
<!--#exec cgi="/cgi-bin/counter.cgi-nd"--> |
| -ord |
displays ordered count 1st2nd3rd..etc |
<!--#exec cgi="/cgi-bin/counter.cgi-ord"--> |
It will work for any page you want as long as the extension is .shtml .
An example can be found in your user directory. You can type http://www.Yourname.com/count.shtml
in your browser to try it out.
You can download this file as an example to help you include SSI counters
on your pages.
This will call a program named counter.cgi in your /cgi-bin directory.
It also uses a file called access_count also located in your /cgi-bin
directory.
The counter.cgi script is chmod 755 and the access_count file
is chmod 664 .
Related Topics.
3-4-3 HOW to use a graphical counter
Powered by ROCKCI DIY
Virtual Servers
|