|
Server : Apache/2.4.62 System : FreeBSD fbsdweb2.web.rcn.net 14.1-RELEASE FreeBSD 14.1-RELEASE releng/14.1-n267679-10e31f0946d8 GENERIC amd64 User : www ( 80) PHP Version : 8.3.8 Disable Function : NONE Directory : /domains/panchogun1/Counter/ |
Upload File : |
#!/usr/local/bin/perl
##################################################
####################
# BEFORE TRYING TO EDIT THIS SCRIPT, READ THE README FILE
##################################################
####################
#
# Dream Catchers CGI Scripts Feel free to modify
# Simple Counter this script to your
# Created by Seth Leonard needs, but please
# for Dream Catchers Technologies, Inc. keep this portion so
# that I get credit.
# http://dreamcatchersweb.com/scripts The same goes for
# distribution.
#
# (c)1996/1997 Dream Catchers Technologies, Inc.,
# All Rights Reserved
#
##################################################
####################
# ONLY EDIT THIS PART OF THE SCRIPT!!
$number_of_digits = "";
$end = ".gif";
$pathtocounter = "http://www.panchogun.com/cgi-bin/counter.txt";
$pathtoimages = "http://www.panchogun.com/counter";
$graphics = "yes";
# DO NOT EDIT BELOW THIS LINE!!
##################################################
##########################
# Tell Browser
print ("Content-type: text/html\n\n");
# Get Count
open (COUNTER, "$pathtocounter");
$count = <COUNTER>;
chop ($count) if $count =~ /\n$/;
close (COUNTER);
# Increase Count
$count += 1;
open (COUNTER, ">$pathtocounter");
print COUNTER ("$count");
close (COUNTER);
@digits = split(//, $count);
if ($number_of_digits eq "") {
$howmany = @digits;
} else {
$howmany = $number_of_digits;
}
# Give empty digits a value
$spline = '%0' . $howmany . 'd';
$count = sprintf("$spline", $count);
@digitimages = split(//, $count);
# Print Output Counter
foreach $digitimage (@digitimages) {
if ($graphics eq yes) {
$image = "<img src=$pathtoimages" . "$digitimage" . "$end>\n";
print ("$image");
} else {
$plain = $digitimage;
print ("$plain");
}
}
exit;