Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: Please Save Me From Insanity!!!

by roboticus (Chancellor)
on Feb 09, 2018 at 00:49 UTC ( #1208768=note: print w/replies, xml ) Need Help??

in reply to Please Save Me From Insanity!!!


I'm not a web developer, so I'll grasp at a few straws.

Things I've tried:

  • I pointed my browser at "" and got an "Index of /" page listing cgi-bin as the only entry. It looks like what I'd expect to see when Apache is serving up a directory without an index.html file.
  • I tried clicking the cgi-bin directory and got the (expected) "403: Forbidden" page.
  • I notice that you mentioned that a script was named "", so I tried going to, at which point it gave me a "500: Internal Error" page.
  • Finally, I entered, as I doubt that you have a file named in there, and got a "404: Page Not Found" error.

From that, it appears to me that you need an "index.html" page. I'd suggest trying something trivial like:

<html> <head> <title>CHEESY INDEX PAGE</title></head> <body> And here's a link to <a href="">a page that +doesn't exist</a> as well as a link to <a href="">the sc +ript you have</a> </body> </html>

Since you're getting a 500 error on the perl script, either the web server is misconfigured somehow, or the script is encountering an error while running. So let's try putting a totally simple perl script there to see if it will work. So we want the simplest possible thing. Perhaps just printing something, and nothing else, like this:

#!/usr/bin/perl print "Content-type: text/html\n\n"; print "NOTHING TO SEE HERE!\n";

I used the path /usr/bin/perl, as it looks like it should be either that or /usr/local/bin/perl depending on how I should interpret the dialog near the beginning.

So if it were me, I'd upload the index.html page and the script above into cgi-bin as Then I'd try to hit

I'd hope it would show the cheesy index page. If so, that's one problem down. I'd then try to hit (or just press the link, if the index.html page works properly) and see if we still get a 500 error or not. We it works and we get a blank (or "NOTHING TO SEE HERE"), then it would indicate a problem somewhere in If we still get a 500 error, then I'd try changing the script to use the other path and try again.

Do you have shell access to the machine you're uploading to?

I'll monitor this thread for a while and see how far you're getting.

Update: after reading huck's link to hostgator support, I struck out some irrelevent stuff.

Update: Added the content-type bit. Thanks to tangent for pointing it out!


When your only tool is a hammer, all problems look like your thumb.

Replies are listed 'Best First'.
Re^2: Please Save Me From Insanity!!!
by tangent (Vicar) on Feb 09, 2018 at 01:45 UTC
    Should be:
    #!/usr/bin/perl print "Content-type: text/html\n\n"; print "NOTHING TO SEE HERE!\n";
    If you don't print the header you will get the '500 Internal Server Error'

    Also, what Hostgator support are saying about the PHP file is rubbish, but if you do want to test it then put just this in your index.php:

    <?php echo '<p>Hello World From the PHP File</p>'; ?>
    The first line of the PHP must contain <?php ...
Re^2: Please Save Me From Insanity!!!
by bennierounder (Sexton) on Feb 09, 2018 at 14:38 UTC

    You're a legend m8! All Done and sorted. Now its time for some coding

Re^2: Please Save Me From Insanity!!!
by bennierounder (Sexton) on Feb 09, 2018 at 11:46 UTC

    I'm going to try this now, thank you for this help. Just so you know I'm trialling it on sub domain

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1208768]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (2)
As of 2018-07-21 10:18 GMT
Find Nodes?
    Voting Booth?
    It has been suggested to rename Perl 6 in order to boost its marketing potential. Which name would you prefer?

    Results (446 votes). Check out past polls.