use CGI; my $q=CGI->new(); my $var=$q->path_info();