]> git.ipfire.org Git - thirdparty/AWStats.git/commitdiff
This commit was manufactured by cvs2git to create tag 'AWSTATS_6_9_BETA'. AWSTATS_6_9_BETA
authorcvs2git <admin@example.com>
Sun, 30 Nov 2008 16:02:45 +0000 (16:02 +0000)
committercvs2git <admin@example.com>
Sun, 30 Nov 2008 16:02:45 +0000 (16:02 +0000)
Sprout from master 2008-11-15 16:20:53 UTC eldy 'Fix: Full list of extrasections was not ordered correctly'
Cherrypick from master 2008-11-30 16:02:44 UTC eldy 'Add ax and rs domains':
    README.TXT
    make/makepack-howto.txt
    wwwroot/cgi-bin/awstats.pl
    wwwroot/cgi-bin/lib/domains.pm
    wwwroot/cgi-bin/plugins/geoip_city_maxmind.pm

README.TXT
make/makepack-howto.txt
wwwroot/cgi-bin/awstats.pl
wwwroot/cgi-bin/lib/domains.pm
wwwroot/cgi-bin/plugins/geoip_city_maxmind.pm

index 11ec8376608cbd65e6e78dcb67b9e24afed4d644..c1c51c77622a27055d88c5fa06e20bdc34251655 100644 (file)
@@ -14,7 +14,7 @@ server log files (and even ftp servers or mail logs) on all Operating Systems.
 License: GNU GPL (GNU General Public License. See LICENSE file),
          OSI Certified Open Source Software license.
 Version: 6.9
-Release date: August 2008
+Release date: November 2008
 Platforms: All (Linux, NT, BSD, Solaris and other *NIX's, BeOS, OS/2...)
 Author: Laurent Destailleur <eldy@users.sourceforge.net>
 AWStats official web site and latest version: http://awstats.sourceforge.net
@@ -91,6 +91,7 @@ I - 2) Requirements
        * Your server must log web access in a log file you can read.
        * To run awstats, from command line, your operating system must be able
          to run perl scripts (.pl files).
+       * Perl module "Encode" must be available.
          
        To run awstats as a CGI (for real-time
          statistics), your web server must also be able to run such scripts.
index a36f0224417e229c3501d23bb98c74d2277da8d4..048251ab1111384edf8824abe86fa4cca5937855 100644 (file)
@@ -1,18 +1,18 @@
-***** Actions to do to release *****\r
-- Check all files are commited.\r
-- Update file README.txt\r
-- Update version number in doc files\r
-- Update version number in makepack files\r
-- Update version number and copyright year in awstats.pl file\r
-- Build PAD files\r
-- Build PDF\r
-- Tagger CVS\r
+***** Actions to build a beta or release *****
+- Check all files are commited.
+- Update file README.txt
+- Update version number in doc files
+- Update version number in makepack files
+- Update version number and copyright year in awstats.pl file
+- Build PAD files
+- Build PDF
+- Tagger CVS  (AWSTATS_x_x_BETA or AWSTATS_x_x)
 
-- makepack sur webmin\r
-- makepack sur awstats (If on linux copy awstats_logo1.gif into $RPMDIR/SOURCES)\r
-- Check content of built packages.\r
-- Move build files into "files" directory\r
-- Update web site page index.php\r
-- Upload files and web site on web server\r
-- Upload files on sourceforge\r
-- Send mail on mailing-list\r
+- makepack sur webmin
+- makepack sur awstats (If on linux copy awstats_logo1.gif into $RPMDIR/SOURCES)
+- Check content of built packages.
+- Move build files into "files" directory
+- Update web site page index.php
+- Upload files and web site on web server
+- Upload files on sourceforge (release only)
+- Send mail on mailing-list
index 860b150ec1d0093bfeb2a717b181f380fcde1304..591ad3334215f14c41d471b113d468ea4140e7e0 100644 (file)
@@ -16,6 +16,7 @@ use strict;
 no strict "refs";
 use Time::Local;       # use Time::Local 'timelocal_nocheck' is faster but not supported by all Time::Local modules
 use Socket;
+use Encode;
 
 #------------------------------------------------------------------------------
 # Defines
@@ -3587,16 +3588,10 @@ sub Read_History_With_TmpUpdate {
                                }
                                next;
                        }
-                       if (    $field[0] eq 'LastUpdate'
-                                || $field[0] eq "${xmlrb}LastUpdate" )
+                       if ($field[0] eq 'LastUpdate'
+                                || $field[0] eq "${xmlrb}LastUpdate")
                        {
-                               if ( $LastUpdate < $field[1] ) {
-                                       $LastUpdate = int( $field[1] );
-
-                                       #$LastUpdateLinesRead=int($field[2]);
-                                       #$LastUpdateNewLinesRead=int($field[3]);
-                                       #$LastUpdateLinesCorrupted=int($field[4]);
-                               }
+                               if (! $LastUpdate) { $LastUpdate=int($field[1]); }; 
                                next;
                        }
                        if (    $field[0] eq 'TotalVisits'
@@ -6114,12 +6109,8 @@ sub Save_History {
        }
 
        # General
-       if ( $sectiontosave eq 'general' ) {
-               if ( $LastUpdate <
-                        int("$nowyear$nowmonth$nowday$nowhour$nowmin$nowsec") )
-               {
-                       $LastUpdate = int("$nowyear$nowmonth$nowday$nowhour$nowmin$nowsec");
-               }
+       if ($sectiontosave eq 'general') {
+               $LastUpdate=int("$nowyear$nowmonth$nowday$nowhour$nowmin$nowsec");
                print HISTORYTMP "\n";
                if ($xml) {
                        print HISTORYTMP "<section id='$sectiontosave'><comment>\n";
@@ -7475,7 +7466,8 @@ sub XMLEncode {
 
 #------------------------------------------------------------------------------
 # Function:            Transforms spaces into %20 and special chars by HTML entities as needed in XML/XHTML
-#                              Decoding is done by XMLDecodeFromHisto
+#                              Decoding is done by XMLDecodeFromHisto.
+#                              AWStats data files are stored in ISO-8859-1. 
 # Parameters:  stringtoencode
 # Return:              encodedstring
 #------------------------------------------------------------------------------
@@ -7492,6 +7484,17 @@ sub XMLEncodeForHisto {
        return $string;
 }
 
+#------------------------------------------------------------------------------
+# Function:     Encode an ISO string to PageCode output
+# Parameters:  stringtoencode
+# Return:              encodedstring
+#------------------------------------------------------------------------------
+sub EncodeToPageCode {
+       my $string = shift;
+       if ($PageCode eq 'utf-8') { $string=encode("utf8", $string); }
+       return $string;
+}
+
 #------------------------------------------------------------------------------
 # Function:     Encode a binary string into an ASCII string
 # Parameters:  stringtoencode
@@ -7585,6 +7588,7 @@ sub CleanXSS {
 
 #------------------------------------------------------------------------------
 # Function:     Clean tags in a string
+#                              AWStats data files are stored in ISO-8859-1. 
 # Parameters:   stringtodecode
 # Input:        None
 # Output:       None
index 1f16c869345a16361f678b312670b21c158b6de4..630927b1c4ad5dc2a4659e9c6780ee752a50cb23 100644 (file)
@@ -25,6 +25,7 @@
 'am','Armenia','an','Netherlands Antilles','ao','Angola',
 'aq','Antarctica','ar','Argentina','arpa','Old style Arpanet',
 'as','American Samoa','at','Austria','au','Australia','aw','Aruba',
+'ax','Aland islands',
 'az','Azerbaidjan','ba','Bosnia-Herzegovina','bb','Barbados',
 'bd','Bangladesh','be','Belgium','bf','Burkina Faso','bg','Bulgaria',
 'bh','Bahrain','bi','Burundi','biz','Biz domains','bj','Benin','bm','Bermuda',
@@ -73,7 +74,9 @@
 'pg','Papua New Guinea','ph','Philippines','pk','Pakistan','pl','Poland',
 'pm','Saint Pierre and Miquelon','pn','Pitcairn Island','pr','Puerto Rico','pro','Professional domains',
 'ps','Palestinian Territories','pt','Portugal','pw','Palau','py','Paraguay','qa','Qatar',
-'re','Reunion (French)','ro','Romania','ru','Russian Federation','rw','Rwanda',
+'re','Reunion (French)','ro','Romania',
+'rs','Republic of Serbia',
+'ru','Russian Federation','rw','Rwanda',
 'sa','Saudi Arabia','sb','Solomon Islands','sc','Seychelles',
 'sd','Sudan','se','Sweden','sg','Singapore','sh','Saint Helena','si','Slovenia',
 'sj','Svalbard and Jan Mayen Islands','sk','Slovak Republic','sl','Sierra Leone',
index b7f6cbfa9bc031e740a02dd664895912423800e9..ed1c7508744aec542ccde415544cc3dd4fa88232 100755 (executable)
@@ -1157,7 +1157,7 @@ my %regall=(
 "ET_52","Sumale",
 "ET_53","Tigray",
 "ET_54","YeDebub Biheroch Bihereseboch na Hizboch",
-"FI_01","land",
+"FI_01","Iland",
 "FI_06","Lapland",
 "FI_08","Oulu",
 "FI_13","Southern Finland",
@@ -2124,7 +2124,7 @@ my %regall=(
 "KZ_01","Almaty",
 "KZ_02","Almaty City",
 "KZ_03","Aqmola",
-"KZ_04","Aqtbe",
+"KZ_04","Aqtebe",
 "KZ_05","Astana",
 "KZ_06","Atyrau",
 "KZ_07","West Kazakhstan",
@@ -2245,21 +2245,21 @@ my %regall=(
 "LV_07","Daugavpils",
 "LV_08","Dobeles",
 "LV_09","Gulbenes",
-"LV_10","Jkabpils",
+"LV_10","Jekabpils",
 "LV_11","Jelgava",
 "LV_12","Jelgavas",
 "LV_13","Jurmala",
-"LV_14","Kr�slavas",
+"LV_14","Krelavas",
 "LV_15","Kuldigas",
-"LV_16","Liepja",
-"LV_17","Liepjas",
+"LV_16","Liepeja",
+"LV_17","Liepejas",
 "LV_18","Limbazu",
 "LV_19","Ludzas",
 "LV_20","Madonas",
 "LV_21","Ogres",
 "LV_22","Preilu",
-"LV_23","Rzekne",
-"LV_24","Rzeknes",
+"LV_23","Rezekne",
+"LV_24","Rezeknes",
 "LV_25","Riga",
 "LV_26","Rigas",
 "LV_27","Saldus",
@@ -4389,7 +4389,7 @@ sub AddHTMLGraph_geoip_city_maxmind {
                    print "<td class=\"aws\">".$DomainsHashIDLib{$countrycode}."</td>";
                    my $regionlib=RegionName($countrycode, $regioncode);
                    print "<td class=\"aws\">".($regionlib?$regionlib:'&nbsp;')."</td>";
-                   print "<td class=\"aws\">".ucfirst($city)."</td>";
+                   print "<td class=\"aws\">".ucfirst(EncodeToPageCode($city))."</td>";
                if ($ShowCities =~ /P/i) { print "<td>".($_city_p{$key}?$_city_p{$key}:"&nbsp;")."</td>"; }
                if ($ShowCities =~ /P/i) { print "<td>".($_city_p{$key}?"$p_p %":'&nbsp;')."</td>"; }
                if ($ShowCities =~ /H/i) { print "<td>".($_city_h{$key}?$_city_h{$key}:"&nbsp;")."</td>"; }
@@ -4590,7 +4590,7 @@ sub ShowInfoHost_geoip_city_maxmind {
 #                  else { print "<span style=\"color: #$color_other\">$Message[0]</span>"; }
 #                  print "</td>";
                        print "<td>";
-                   if ($city) { print "$city"; }
+                   if ($city) { print EncodeToPageCode($city); }
                    else { print "<span style=\"color: #$color_other\">$Message[0]</span>"; }
                    print "</td>";
                }
@@ -4626,7 +4626,7 @@ sub ShowInfoHost_geoip_city_maxmind {
 #                  else { print "<span style=\"color: #$color_other\">$Message[0]</span>"; }
 #                  print "</td>";
                        print "<td>";
-                   if ($city) { print "$city"; }
+                   if ($city) { print EncodeToPageCode($city); }
                    else { print "<span style=\"color: #$color_other\">$Message[0]</span>"; }
                        print "</td>";
                }
@@ -4811,14 +4811,14 @@ sub SectionWriteHistory_geoip_city_maxmind {
                #my $page=$_city_p{$_}||0;
                #my $bytes=$_city_k{$_}||0;
                #my $lastaccess=$_city_l{$_}||'';
-               print HISTORYTMP "${xmlrb}$_${xmlrs}0${xmlrs}", $_city_h{$_}, "${xmlrs}0${xmlrs}0${xmlre}\n"; next;
+               print HISTORYTMP "${xmlrb}".XMLEncodeForHisto($_)."${xmlrs}0${xmlrs}", $_city_h{$_}, "${xmlrs}0${xmlrs}0${xmlre}\n"; next;
        }
        foreach (keys %_city_h) {
                if ($keysinkeylist{$_}) { next; }
                #my $page=$_city_p{$_}||0;
                #my $bytes=$_city_k{$_}||0;
                #my $lastaccess=$_city_l{$_}||'';
-               print HISTORYTMP "${xmlrb}$_${xmlrs}0${xmlrs}", $_city_h{$_}, "${xmlrs}0${xmlrs}0${xmlre}\n"; next;
+               print HISTORYTMP "${xmlrb}".XMLEncodeForHisto($_)."${xmlrs}0${xmlrs}", $_city_h{$_}, "${xmlrs}0${xmlrs}0${xmlre}\n"; next;
        }
        print HISTORYTMP "${xmleb}END_PLUGIN_geoip_city_maxmind${xmlee}\n";
        # ----->