Skip Navigation

OneNet

Oklahoma’s Telecommunications Network

Counters

OneNet Counter 2.5

This service is for OneNet Clients only!

Adding a counter to a page is very easy. All you need to do is code an “IMG SRC=…>” tag in your page that calls the counter program.

IMPORTANT: Be sure to include in the IMG SRC tag to the OneNet website information like:

<IMG SRC=”http://www.onenet.net/…>”

For instance, this page has been accessed, times so far. The HTML tag to generate that graphic is just:

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=whatever.count” align=absmiddle>

Now the counter program is very powerful, and this page only shows a couple simple examples. The only feature used in the preceding example is the “df” option which let’s you name the file used to hold the count. Every page which contains a reference to the “Count.cgi” script with the same filename on the “df=XXX” tag will update the same number. So you can share counters among a number of pages, or have independent counters. For more information on the counter program, please refer to the author’s extensive notes on the subject. The URL for his homepage is http://www.muquit.com

The counter doesn’t seem to increment, wonder what’s going on?

The counter only increments, if the visitor’s IP and he one in the datafile (the last visitor) differs. It’s there to handle occasions when people press the “Reload” button continuously.

Here’s an example, using the Count.cgi script to print a digital clock instead of a page counter. The current time in Oklahoma is:

To change the time zones you only need to add timezone=GMT-0100 for any difference from GMT.

And again, the code is very simple,

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=clock”>

Here are some examples of the very extensive options available for controlling the look and feel of the counter program. Please refer to the author’s homepage for complete documentation. You can cut-n-paste any of the following and experiment if you’d like. The HTML required to produce each of them is listed to the right of the graphic.

To set the initial value of the counter, use the “st=” option. The minimum value for this option is 1. If none is specified, then 1 will be assumed. You can not reset the counter once the counter file is created.

ATTENTION: The “df=” option in the examples below designates the disk file that contains the actual count to be displayed. Do not use the “df=” option as displayed below. The “df=” option should contain a file name unique to your site.

The “dd=” option controls the digit style.


<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile1|dd=A”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=B”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=C”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=D”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=E”>

The following samples are for clocks:


<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=clock”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=clock|chcolor=T”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=clock|dd=B”>


<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=clock|dd=C”>

The following are samples for dates and count down to, from and difference.


<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=date&ampdformat=ddmmyyy”>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=date&ampdformat=mmddyyy”>


<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?display=date&ampdd=cdr”>

Count down clock:

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?cdt=2000;12;31;8;0;0&ampsfd=T&ampdd=cd&ampft=2&ampnegate=T”>

Difference between Jul 16, 1999 and Jul,. 31 1999

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?cdf=1999;7;16;22;0;0&ampcdt=1999;7;31;10;0;0″>

The “ft=” option controls the width of the frame border.
The “frgb=” option controls the color of the frame border.



<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=B|ft=0″>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=B|ft=5″>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=B|ft=10″>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|ft=12|frgb=25;80;8″>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=B|ft=10|frgb=180;30;12″>

You can make the counter images opaque with the “tr=1″ (transparency) option.


<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|ft=0|tr=1″>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|ft=12|tr=1|frgb=25;80;8″>

<IMG SRC=”http://www.onenet.net/cgi-bin/Count.cgi?df=cfile|dd=C|ft=10|tr=1|frgb=180;130;2″>