in reply to the 500 error

A few things to consider. $ct is not defined in your code. use strict; would catch that for you before you uploaded and tried to run the code.

Also in HTML 4 a title is manditory in the head section of the html. (I don't think that is the 500 error source but it will make your page not validate)

I am assuming that since hello world works that the perl is where you think it is (/usr/bin/perl) and that is installed and available to you.

Also, if taint checking is on your script will abort due to the fact that you used $cf from an outside source without untainting it.

Replies are listed 'Best First'.
Re^2: the 500 error
by tachyon (Chancellor) on Oct 23, 2004 at 11:13 UTC

    if taint checking is on your script will abort

    Actually it won't. Taint looks to see if you do dangerous things with external vars. Printing is not dangerous. Invalid HTML will never cause a 500 error BTW.

    [root@devel3 root]# cat #!/usr/bin/perl -wT use strict; use CGI; my $q = new CGI; print $q->header(); my $ct = $q->param('ct'); print $ct; [root@devel3 root]# ./ ct=foo%0A Content-Type: text/html; charset=ISO-8859-1 foo [root@devel3 root]#