Skip to content


awstats按日产生统计报表

修改wwwroot/cgi-bin/awstats.pl 

7851行增加日期下拉框

[code]     print “<select class=\"awsformfield\” name=\”day\”>\n”;     foreach (1..31) {      my $dayix=sprintf(“%02s”,$);      print “$dayix\n”;     }     print “\n”; [/code]

7871行增加databasebreak参数

[code]     if ($DatabaseBreak) { print “\n”; } [/code]

命令行统计增加:-databasebreak=day

查看报表时地址栏需增加:&databasebreak=day&day=DD

以下为查看页代码  [code]

    var   d   =   new   Date();    d.setTime(d.setDate(d.getDate()-1));    var day=d.getDate();  

 var srv = new Array();

 srv[0]=’www.c1gstudio.com’;  srv[1]=’bbs.c1gstudio.com’;  srv[2]=’blog.c1gstudio.com’;  srv[3]=’admin.c1gstudio.com’;

 for (var i=0;i<srv.length ;i++ )  {  document.writeln('

<a href="http://admin.c1gstudio.com/cgi-bin/awstats.pl?config=’+srv[i]+’&databasebreak=day&day=’+day+'” target=”_blank”>http://admin.c1gstudio.com/cgi-bin/awstats.pl?config=’+srv[i]+'</a></p&gt;’);  }  document.writeln(‘


‘); [/code]

参考: http://blogger.org.cn/blog/more.asp?name=chenjiejacky&id=20464 http://www.chedong.com/blog/archives/001293.html#more

Posted in linux 维护优化, 技术.

Tagged with , .


4 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

  1. ZK says

    有稍微详细点的么》??

    7851行增加日期下拉框

    顺序不太对。。 我修改过。。所以找这行有点费劲!呵呵

  2. C1G says


    7846行是# Print selected period of analysis (month and year required)

    你可以再导一份原始文件。

  3. 医保网 says

    awstats 7 是9688行

  4. 医保网 says

    错了,awstats 7 是9866行



Some HTML is OK

or, reply to this post via trackback.