From 82c22fc8668e9a706c0459a164c0a571128993b7 Mon Sep 17 00:00:00 2001 From: Renato Botelho Date: Fri, 17 Jan 2014 14:22:48 -0200 Subject: Remove ifBWStats, it's broken since 2010 --- config/ifbwstats/ifbwstats_daily.php | 142 ----------------------------------- 1 file changed, 142 deletions(-) delete mode 100644 config/ifbwstats/ifbwstats_daily.php (limited to 'config/ifbwstats/ifbwstats_daily.php') diff --git a/config/ifbwstats/ifbwstats_daily.php b/config/ifbwstats/ifbwstats_daily.php deleted file mode 100644 index 1bd29ea2..00000000 --- a/config/ifbwstats/ifbwstats_daily.php +++ /dev/null @@ -1,142 +0,0 @@ -'; -include("fbegin.inc"); -echo '

ifBWStats: Daily Statistics For '.$interfacename.'

'; -echo 'Month Ending: '.str_replace('%20', ' ', $queryparts[3]).'

'; - -//display tabs -echo ''; -echo ''; -echo ''; -echo '
'; -$tab_array[0] = array ("Daily", false, "ifbwstats_cur.php"); -$tab_array[1] = array ("Monthly", false, "ifbwstats_disp.php"); -$tab_array[2] = array ("Settings", false, "pkg_edit.php?xml=ifbwstats.xml"); -$tab_array[3] = array ("Archive", true, $url); -display_top_tabs($tab_array); -echo '
'; -echo '
'; - -$foundfile = 'null'; -if (file_exists($queryparts[0])) $foundfile = $queryparts[0]; -if ($foundfile == 'null') -{ - echo 'Sorry, no data file found.'; -} -else -{ - $fp = fopen($foundfile,"r") or die("Error Reading File"); - $data = fread($fp, filesize($foundfile)); - fclose($fp); - $wandataall = explode("\n", $data); - $n = count($wandataall); - - $monthintotal = 0; - $monthouttotal = 0; - $monthdaystart = 0; - - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - - for ($i=$queryparts[1] ; $i < $queryparts[2]+1 ; $i++ ) - { - $dataset=explode("|", $wandataall[$i]); - $dateset=explode("-", $dataset[0]); - $monthintotal = $monthintotal + $dataset[1]; - $monthouttotal = $monthouttotal + $dataset[2]; - $total = round((($dataset[1]+$dataset[2])/1024/1024/1024),2); - $dataset[1] = round(($dataset[1]/1024/1024),2); - $dataset[2] = round(($dataset[2]/1024/1024),2); - - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - } - - $total = round((($monthintotal + $monthouttotal)/1024/1024/1024),2); - $monthintotal = round(($monthintotal/1024/1024/1024),2); - $monthouttotal = round(($monthouttotal/1024/1024/1024),2); - - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo '
DateDownloadedUploadedTotal Transfered
'.$dataset[0].''.$dataset[1].'MB'.$dataset[2].'MB'.$total.'GB
Month Totals↓'.$monthintotal.'GB↑'.$monthouttotal.'GB↕'.$total.'GB
'; -} - -echo '
'; -echo '
'; - -include("fend.inc"); -echo ''; -echo ''; - -?> \ No newline at end of file -- cgit v1.2.3