CGI Scripts by Kevin

Multi-Log v.1b

In Short:

This script will log multiple pages and display the results in one central table. It displays stats from that day, previous day, week, previous week, month, previous month, and year to date.

Demo:

Click here

Instructions:

multi-log.pl
There is only one variable to define in this script. Set $datafile to a file in a directory where the HTTPd has permission to write. I set it to /my/home/dir/www/sys-logs/multi-log.data and chmod'd that directory 777. Upload in ASCII to your CGI directory and chmod multi-log.pl 775.

From your shell
Change to your cgi-bin directory and type
perl multi-log.pl init
. Now you are ready to add pages to log. Type
perl multi-log.pl add newalias Real name of that Page
where alias is just a small abbreviation for the page name, and "Real name of Page" is the name you want to show up on the stats table. For example, I typed
perl multi-log.pl add tdimh This Day In Music History
for one of my pages.

If your server supports <!--#exec cmd's
Simply put
<!--#exec cmd="/usr/local/bin/perl /path/to/multi-log.pl log thispagealias"-->
and that'll take care of logging. To view the stats table embed
<!--#exec cmd="/usr/local/bin/perl /path/to/multi-log.pl show"-->

Otherwise...
You will need to modify multi-gw.pl for the script to work through a tunnel. See the individual instruction on multi-gw.pl for more information.

Also, be sure to check out the included index.shtml for the JavaScript code to refresh the page every 20 mintues.


Download:

Click here

"By downloading this script I agree to indemnify DataDragon Information Services from any damage that could be done by this script. In other words, it's my own tough cookies if this script wreaks havok on my web server."

Register:

EMail:
Location Used:
Script:
Subscribe to List:YesNo

cgi-scripts@DataDragon.com
  Listing of Scripts

Other Resources