From: eldy <> Date: Sun, 23 Nov 2003 04:50:36 +0000 (+0000) Subject: Reports look better on Mozilla browsers. X-Git-Tag: AWSTATS_6_0_BETA~72 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=374e418b0d2f049fa33772ef356c1b5fcaed4e03;p=thirdparty%2FAWStats.git Reports look better on Mozilla browsers. --- diff --git a/wwwroot/cgi-bin/awstats.pl b/wwwroot/cgi-bin/awstats.pl index c5e9f927..fea6e006 100644 --- a/wwwroot/cgi-bin/awstats.pl +++ b/wwwroot/cgi-bin/awstats.pl @@ -548,8 +548,8 @@ print < \n"; print "\n"; - if ($width == 70 && $QueryString =~ /buildpdf/i) { print "\n"; } - else { print "
\n"; } + if ($width == 70 && $QueryString =~ /buildpdf/i) { print "
\n"; } + else { print "
\n"; } } #------------------------------------------------------------------------------ @@ -7784,11 +7784,15 @@ if (scalar keys %HTMLOutput) { foreach my $family (@OSFamily) { my $p=' '; if ($Total) { $p=int($totalfamily_h{$family}/$Total*1000)/10; $p="$p %"; } - print ""; - print ""; - print "\n"; + my $familyheadershown=0; foreach my $key (reverse sort keys %_os_h) { if ($key =~ /^$family(.*)/i) { + if (! $familyheadershown) { + print ""; + print ""; + print "\n"; + $familyheadershown=1; + } $keysinkeylist{$key}=1; my $ver=$1; my $p=' '; @@ -7810,11 +7814,15 @@ if (scalar keys %HTMLOutput) { } } # Write other records - print ""; - print ""; - print "\n"; + my $familyheadershown=0; foreach my $key (@keylist) { if ($keysinkeylist{$key}) { next; } + if (! $familyheadershown) { + print ""; + print ""; + print "\n"; + $familyheadershown=1; + } my $p=' '; if ($Total) { $p=int($_os_h{$key}/$Total*1000)/10; $p="$p %"; } print ""; @@ -7866,11 +7874,15 @@ if (scalar keys %HTMLOutput) { foreach my $family (sort { $BrowsersFamily{$a} <=> $BrowsersFamily{$b} } keys %BrowsersFamily) { my $p=' '; if ($Total) { $p=int($totalfamily_h{$family}/$Total*1000)/10; $p="$p %"; } - print ""; - print ""; - print "\n"; + my $familyheadershown=0; foreach my $key (reverse sort keys %_browser_h) { if ($key =~ /^$family(.*)/i) { + if (! $familyheadershown) { + print ""; + print ""; + print "\n"; + $familyheadershown=1; + } $keysinkeylist{$key}=1; my $ver=$1; my $p=' '; @@ -7893,11 +7905,15 @@ if (scalar keys %HTMLOutput) { } } # Write other records - print ""; - print ""; - print "\n"; + my $familyheadershown=0; foreach my $key (@keylist) { if ($keysinkeylist{$key}) { next; } + if (! $familyheadershown) { + print ""; + print ""; + print "\n"; + $familyheadershown=1; + } my $p=' '; if ($Total) { $p=int($_browser_h{$key}/$Total*1000)/10; $p="$p %"; } print "";
".uc($family)."".int($totalfamily_h{$family})."$p 
".uc($family)."".int($totalfamily_h{$family})."$p 
".uc($Message[2])."   
".uc($Message[2])."   
".uc($family)." ".int($totalfamily_h{$family})."$p 
".uc($family)." ".int($totalfamily_h{$family})."$p 
".uc($Message[2])."    
".uc($Message[2])."