Ok thanks for the help and ideas so far.
Yes part of my initial script was clipped in the quote. I also tried changing the perl directory to /usr/local/bin/perl but that didnt do anything. The path in the cpanel shows it to be /usr/bin/perl. Good catch on the print "Content-type: text/html"; ... the original script I'm trying to get working had it, my sample did not.
I did some more digging into error logs and determined it to be a 500 error: Premature end of script headers. Yea these suck
Here is my current script that errors out:
(http://www.huntingnut.com/cgi-bin/zz.pl)
There is very very little to go wrong here. In fact if I delete it all but the #!/usr/bin/perl it will still error. As I said, I've also tried #!/usr/local/bin/perl with the same results.
THIS STRONGLY MAKES ME SUSPECT THE PATH IS INCORRECT. Cpanel shows the path to be #!/usr/bin/perl ... /shrug
I verified via 2 different apps I was uploading the file in Ascii Mode. I even went as far as deleting the file, creating it through cpanel, editing it and putting back in the code. Nada. CHMODs are correct (755)
I've written quite a few PERL scripts so its not like I'm a total newbie at this, but darned if I can see what is wrong. Guess I could re-write everything in PHP but that poses problems of its own as its tricker to integrate into CPGNuke, I'm learning PhP quickly but it would still take some time before the old systems were up and functional again.
I did alot of searching around here in the forums and I see ALOT of people who had this same issue. There are a ton of Support peeps saying "I'm not a perl expert but hang in there, someone will help", then a few pieces of advice but I've yet to see a post here where someone really said they had a similar issue that was cleared up by fixing something minor.
I dunno... I've tried about every permutation I can think of... running out of ideas quickly though.