#!/usr/bin/perl use CGI; my $cgi = new CGI; if ($cgi->param('smbt')) { &creat_cooke(); # sic exit print $cgi->redirect('http://example.com/path/Welcome.cgi'); } print $cgi->header(); # [...]