#!/usr/bin/perl # # screensaver.cgi - redirect and log users downloading the screensavers. # # (C) Copyright 2004, Nicholas Johnston # # Development history: # ------------------- # - 27 April 2004: development started. # # Redistribution without the expressed written permission of DeepLake # Entertainment UK or Nicholas Johnston is forbidden. Mere access to this # source code does not give you the right to use it. # BEGIN { unshift @INC, "../scripts"; # so we can get deeplake.pm use CGI::Carp qw(fatalsToBrowser); } use strict; use deeplake; use CGI; my $cgi = new CGI; my $team = $cgi->param('team'); my %team_installers; foreach my $file (qw(arsenal manutd liverpool chelsea liverpool rangers celtic england)) { # TODO - fix this properly $team_installers{$file} = ($file eq 'england') ? 'england2.exe' : "${file}1.exe"; } deeplake::logfile("Redirecting user to " . $team_installers{$team}); print $cgi->redirect($team_installers{$team});