#!/usr/bin/perl -T use strict; use warnings; use CGI; my $q = CGI->new; # send a redirect print $q->header(-location => 'http://www.foo.com/bar.html');