Same problem; different circumstance (code - not script)
I tested a simple, nice guestbook script on my local server and it worked great! Uploaded to my ISP and...code when the url is entered:
I've run several scripts with them before and tried to address some of the problems had in the past (i.e. using fromDOS to remove line endings to suit Unix, etc.) - with no luck.
Could it be that the server or perl can't recognize this as executable
because it has no extension, or something? [I can't seem to figure this one out.]
Any help would be super,
perl cgi error message
Exactly what error message are you seeing ?
Sorry about that!
[I got so frustrated that I spent a lot of time searching for a replacement - it's installed, and not bad - but no calendar listing of posts, which is a drag...]
There *was* no error message - when called, as shown above, the script showed as text!!
That's why I'm thinking "server", since all worked fine locally (yes, params were changed for uploading, but you know what I mean).
Any suggestions? (It's still laying around here, somewhere...)
If you're seeing code, you either have your script in the wrong directory on the server, and the server doesn't have the AddHandler .cgi set, in which case you need to move the script to your script directory (probably cgi-bin somewhere on the server). Either that or your script has the wrong extension for executables (some servers are picky about .pl being .cgi and if you don't have an extesion at all, that would probably do it) or the server's not set up to handle scripts at all and just pushes it as text (though if you've run scripts there before, that obviously not the problem).
Also, make sure your shebang line is correct for the server (the line at the top that says #!/server/path/to/perl), if it's a *nix server, you may not need the extension if the shebang is right - depending on your configuration.
Actually, script was in cgi-bin and my server admin said it should've worked - even without an extension; but it didn't!
Still at a loss for this one, I think - thanks for your ideas, anyway.
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)