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 CGI.pm 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.