Count all audio files together.
This commit is contained in:
parent
0e19c374f7
commit
20dbc2d584
1 changed files with 3 additions and 0 deletions
|
@ -27,6 +27,9 @@ while (<>) {
|
|||
my($ip, $method, $url) = ($1, $2, $3);
|
||||
next unless $method =~ /^\s*GET\s*$/i;
|
||||
|
||||
$url =~ s/\s*\.(ogg|mp3)\s*$/.audio/i; # Treat ogg and mp3 downloads same.
|
||||
$url =~ s/\s*\/$$//; # Always remove trailing slash
|
||||
|
||||
$data{$url}{$ip} = 0 unless defined $data{$url}{$ip};
|
||||
$data{$url}{__TOTAL__} = 0 unless defined $data{$url}{__TOTAL__};
|
||||
$data{$url}{$ip}++;
|
||||
|
|
Loading…
Add table
Reference in a new issue