From: eldy <> Date: Sun, 5 Dec 2004 22:40:09 +0000 (+0000) Subject: webmin: Add link to popup to show geoip data file version X-Git-Tag: AWSTATS_6_3_RELEASE~55 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ce5c3dd7a7695d9dc232305df6bb85bba30ef646;p=thirdparty%2FAWStats.git webmin: Add link to popup to show geoip data file version --- diff --git a/tools/webmin/awstats/config.info b/tools/webmin/awstats/config.info index 09862323..44bcf874 100644 --- a/tools/webmin/awstats/config.info +++ b/tools/webmin/awstats/config.info @@ -1,6 +1,6 @@ awstats=Absolute filesystem path to AWStats (CLI),0 awstats_cgi=Absolute or relative URL path to AWStats (CGI),0 alt_conf=Sample AWStats configuration file,3,/etc/awstats/awstats.model.conf -plugin_1_geoip_=Path for GeoIP country database file (if AWStats geoip plugin is enabled),3,/usr/local/share/GeoIP/GeoIP.dat -plugin_2_geoip_region=Path for GeoIP region database file (if AWStats geoip_region_maxmind plugin is enabled),3,/usr/local/share/GeoIP/GeoIPRegion.dat +plugin_1_geoip=Path for GeoIP country database file (if AWStats geoip plugin is enabled),3,/usr/local/share/GeoIP/GeoIP.dat +plugin_2_geoip_region_maxmind=Path for GeoIP region database file (if AWStats geoip_region_maxmind plugin is enabled),3,/usr/local/share/GeoIP/GeoIPRegion.dat plugin_3_geoip_city_maxmind=Path for GeoIP city database file (if AWStats geoip_city_maxmind plugin is enabled),3,/usr/local/share/GeoIP/GeoIPCity.dat diff --git a/tools/webmin/awstats/edit_config.cgi b/tools/webmin/awstats/edit_config.cgi index e641d5a1..04acdf90 100644 --- a/tools/webmin/awstats/edit_config.cgi +++ b/tools/webmin/awstats/edit_config.cgi @@ -566,7 +566,18 @@ if ($in{'advanced'} == 4) { print " Loaded plugins Plugin's parameters   \n"; foreach my $key (0..(@pconfparam-1)) { - print " $pconfparam[$key] "; + print " $pconfparam[$key] "; + my ($p,$geoipdatafile)=(); + if ($pconfparam[$key] =~ /^geoip$/) { $p="GeoIP Country"; $geoipdatafile=$config{'plugin_1_geoip'}||"/usr/local/share/GeoIP/GeoIP.dat"; } + if ($pconfparam[$key] =~ /^geoip_region_maxmind$/) { $p="GeoIP Region"; $geoipdatafile=$config{'plugin_2_geoip_region_maxmind'}||"/usr/local/share/GeoIP/GeoIPRegion.dat"; } + if ($pconfparam[$key] =~ /^geoip_city_maxmind$/) { $p="GeoIP City"; $geoipdatafile=$config{'plugin_3_geoip_city_maxmind'}||"/usr/local/share/GeoIP/GeoIPCity.dat"; } + if ($p) { + # If a geoip plugin + my $datafile=$geoipdatafile; + if ($pconfvaluep[$key] =~ /^\w+\s+(.+)$/) { $datafile=$1; } + print "$p database version"; + } + print " "; print &hblink($text{'help_help'}, "help.cgi?param=plugin_$pconfparam[$key]")." \n"; } print " $text{'index_hideadvanced'} \n";