aboutsummaryrefslogtreecommitdiff
path: root/html/hits
diff options
context:
space:
mode:
authorDavid Aspinall2001-09-09 17:54:22 +0000
committerDavid Aspinall2001-09-09 17:54:22 +0000
commit4774e8e4c1284eb1adb4e992e9b57b00d5e9157f (patch)
tree9436e24c0b008af0b0dbd7f2d679b01645e5af50 /html/hits
parent86c0afef58939aabd968494329d8689cf3b8a3fc (diff)
Renamed file
Diffstat (limited to 'html/hits')
-rw-r--r--html/hits26
1 files changed, 26 insertions, 0 deletions
diff --git a/html/hits b/html/hits
new file mode 100644
index 00000000..6d5c2be6
--- /dev/null
+++ b/html/hits
@@ -0,0 +1,26 @@
+<?php
+ $counterFile = "counter.txt";
+ $counterStart = "counterstart.txt";
+ $maxlen=10;
+ require('functions.php3');
+ small_header("Hit counter");
+ print "<p>";
+ if (is_readable($counterFile)) {
+ print "These pages have been accessed ";
+ readfile($counterFile);
+ print " times ";
+ if (is_readable($counterStart)) {
+ $fp=fopen($counterStart,"r");
+ $start=fgets($fp,20);
+ print "since ";
+ print strftime("%d %B %Y",$start);
+ print ".\n";
+ } else {
+ print "<br>\n(could not access time stamp file $counterStart)\n";
+ };
+ } else {
+ echo "Could not access hit counter file $counterFile\n";
+ };
+ print "</p>";
+ footer();
+?>