Wednesday, January 11, 2012

Debugging tips for #perl tfmail.pl on a shared host with no logs , and windows on it ...

Well the story is that the tfmail.pl shows only this
Application Error An error has occurred in the program so no debug errors or anything else
I had to add debug mode for the script and saw this tip how to do it :

With Perl there is something you can try that will attempt to redirect error messages to the browser so you can attempt to diagnose the problem. Open the script in your text editor, and under the path to Perl on the first line, place this:
use CGI::Carp qw(fatalsToBrowser);
Only then I saw that LOGFILE_ROOT was set to '.' and that made the script die I have fixed the line
use constant LOGFILE_ROOT   => '';
and reuploaded and all was ok after that

No comments: