This commit is contained in:
2025-09-15 16:30:24 -06:00
parent a4ff18076a
commit 6e23de8f12
61 changed files with 1103 additions and 687 deletions

39
irpg-web/footer.php Normal file
View File

@@ -0,0 +1,39 @@
</div>
<div class="footer">
<p class="small">
Questions? Comments? Suggestions? Bugs? Naked pics?
<?php
if ($irpg_site_email != null && $irpg_site_email != "disabled") {
echo " <a href=\"contact.php\">$admin_email</a> or\n";
}
echo " ".$admin_nick."@IRC.\n";
?>
<?php
$hits = file("hits.db");
$fp = fopen("hits.db", "w");
$thispage = explode("/",$_SERVER['PHP_SELF']);
$thispage = array_pop($thispage);
if ($fp == false) {
echo " Error: could not open file hits.db.";
}
foreach ($hits as $line) {
list($page,$numhits,$date) = explode("\t",trim($line));
if ($page == $thispage) {
++$numhits;
echo " $numhits hits since $date\n";
$found = 1;
}
if ($fp) {
fwrite($fp,"$page\t$numhits\t$date\n");
}
}
if (!$found && $fp) {
echo " 1 hit since ".date("M j, Y",time())."\n";
fwrite($fp,$thispage."\t1\t".date("M j, Y",time())."\n");
}
fclose($fp);
?>
</p>
</div>
</body>
</html>