cl58 Posted June 5, 2011 Share Posted June 5, 2011 I'm trying to run pisg which is a perl script. The documentation says to run the script via shell, but I chmod'd the script to 755 (executable) so it should be running just from going to the file, right? I'm getting a 500 error for some reason and I can't figure out why. The script is at http://www.cl58services.co.cc/pisg/pisg.pl and you can see the code of the script at http://www.cl58services.co.cc/pisg/pisgcode Quote Link to comment Share on other sites More sharing options...
Byron Posted June 5, 2011 Share Posted June 5, 2011 Add this near the top of your script: BEGIN { use CGI::Carp qw(carpout); use diagnostics; open(LOG, ">errors.txt"); carpout(LOG); close(LOG); } use CGI::Carp qw(fatalsToBrowser); And see if you get any errors written to the errors.txt file. Quote Link to comment Share on other sites More sharing options...
cl58 Posted June 5, 2011 Author Share Posted June 5, 2011 No errors: http://www.cl58services.co.cc/pisg/errors.txt Quote Link to comment Share on other sites More sharing options...
Guest Geoff Posted June 5, 2011 Share Posted June 5, 2011 root@stevie [/home/cl58/public_html/cl58services.co.cc/pisg]# ./pisg.pl pisg v0.72 - Perl IRC Statistics Generator Using config file: pisg.cfg Statistics for channel #sv @ irc.mozilla.org by MAINTAINER 1 logfile(s) found, using mIRC format... Analyzing log svlog.log... 0 days, 0 lines total Channel analyzed successfully in 00 hours, 00 minutes and 00 seconds on Sun Jun 5 09:38:32 2011 Maybe you need to output HTTP headers first. Quote Link to comment Share on other sites More sharing options...
cl58 Posted June 5, 2011 Author Share Posted June 5, 2011 I know almost nothing about Perl, so sorry, but how would I do that? Quote Link to comment Share on other sites More sharing options...
Guest Geoff Posted June 5, 2011 Share Posted June 5, 2011 Well, Perl is one of the few scripting languages that I have not learned, so I just copied this off the internet: print "Content-type: text/html\n\n"; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.