summaryrefslogtreecommitdiff
path: root/versions.php
diff options
context:
space:
mode:
authorBen Longbons <b.r.longbons@gmail.com>2011-06-18 21:58:47 -0700
committerBen Longbons <b.r.longbons@gmail.com>2011-06-19 14:19:55 -0700
commitbae4b92e560c2694eaaf0e8b4d9e95e56204471b (patch)
tree4acc120f6a94cfbf9694bf344658493de5aaa67b /versions.php
parent319f80526f8585ecadaec986e37c9bd326f4d363 (diff)
downloadserverdata-bae4b92e560c2694eaaf0e8b4d9e95e56204471b.tar.gz
serverdata-bae4b92e560c2694eaaf0e8b4d9e95e56204471b.tar.bz2
serverdata-bae4b92e560c2694eaaf0e8b4d9e95e56204471b.tar.xz
serverdata-bae4b92e560c2694eaaf0e8b4d9e95e56204471b.zip
Move to a subdirectory
Diffstat (limited to 'versions.php')
-rw-r--r--versions.php25
1 files changed, 0 insertions, 25 deletions
diff --git a/versions.php b/versions.php
deleted file mode 100644
index 601fb252..00000000
--- a/versions.php
+++ /dev/null
@@ -1,25 +0,0 @@
-<?php
-$file = 'versions/' . date('Y-m-d') . '.txt';
-if (!file_exists($file)) touch($file); // Make sure it exists
-
-$versions = file($file);
-$verinfo = array();
-foreach($versions as $version) {
- $ver = substr($version, 8); // Ignore time information
- if ($verinfo[$ver] != null) {
- $verinfo[$ver]++;
- } else {
- $verinfo[$ver] = 1;
- }
-}
-
-arsort($verinfo);
-
-$total = count($versions);
-print '<table border="1px" cellspacing="0px" cellpadding="1px"><tr><th>Client</th><th title="Count">n</th><th title="Percent of total">%</th></tr>';
-foreach($verinfo as $vi=>$vc) {
- echo '<tr><td>' . htmlspecialchars($vi) . '</td><td>' . $vc . '</td><td>' . round((100 / $total) * $vc, 2) . '</td></tr>';
-}
-print '</table><br />Total number of connections: ' . $total . '<br />Number of different clients reported: '
- . count($verinfo) . '<br /><br />Data retrieved: ' . date('D M d y, g:i a T', filemtime($file));
-?>