Welcome to WebmasterWorld Guest from 184.108.40.206
I'm trying to link to a file, fileA.cgi, which is in the cgi-bin directory in a folder called chap01- from fileA.html.
When I press on a link in fileA.html, I get an Internal Server Error. Just to test it out I created another cgi file called fileB.cgi in the same folder. When I link to it from the same .html page I get the results of the cgi file.
Both .cgi scripts are set to CHMOD 755 and were uploaded as an ASCII. All I did was change the filename in the link, so how come one works and the other doesn't?
I checked for errors using the command line...syntax was OK. I also checked to make sure I could output the .cgi file in question using the command line and everything was fine. I just can't do it from the browser.
Any help is greatly appreciated.
I had a similar problem the other day. A file that had been working for a long time suddenly stopped working, right after I uploaded and overwrote it. The error log said "fopen permission denied" or something like that, so it wasn't a syntax problem.
To make a long story short, my FTP client was telling me that it was set to have execute permissions, but it didn't really have execute permissions. I refreshed a number of times, and it still showed that it had execute permissions, but it really didn't.
Here's what I'd do if I were you: Place the following in your Perl code, at the very start of your code (at the very start of where you actually start issuing commands)
Upload it to your server, and execute the script.
Then check your error log and see if it mentions "somethingunique".
If it doesn't, then it means that it hasn't even made it to the first command/expression/statement. In that case, it's probably a file permissions thing.
Hope that helps,