diff --git a/server/conf/awstats_index.php.master b/server/conf/awstats_index.php.master index b3e694ebbf3441038b45508f8e1e1624c3a0f481..86eec8a73dea0038a4d4e9c77e8088e3d20a44cd 100644 --- a/server/conf/awstats_index.php.master +++ b/server/conf/awstats_index.php.master @@ -43,23 +43,17 @@ if ($handle = opendir('.')) arsort($awprev); $options = ""; -foreach ($awprev as $key => $value) -{ - - if(file_exists($value.'/awsindex.html') && file_exists($value.'/goaindex.html')) { - $awstatsindex = 'awsindex.html'; - } elseif(file_exists($value.'/awsindex.html') && !file_exists($value.'/goaindex.html')) { - $awstatsindex = 'awsindex.html'; - } else { - $awstatsindex = 'goaindex.html'; - } - +foreach ($awprev as $key => $value) { + // Define name for the index file + $awstatsindex = 'awsindex.html'; + if(!file_exists($value.'/awsindex.html') && file_exists($value.'/goaindex.html')) { + $awstatsindex = 'goaindex.html'; + } + // Set name for first entry in month list if($key == $current) $options .= "\n"; else $options .= "\n"; } -$awstatsindex = 'awsindex.html'; - $html = "\n\n\nStats\n"; $html .= "