[thelist] Weird Log Entries
Matthew Brooks
m at pleonasm.com
Thu Aug 2 17:27:03 CDT 2001
More than one person wrote:
> Code Red.
Ah, that explains why it's once a month, then. Thank you. Not IIS, so all OK.
<tip type="Perl CGI">
In Perl CGI scripts, trap die in called functions thus:
eval {
&main_function($whatever);
1;
} or do {
&oops();
}
If main_function dies, instead of the usual blank screen or user-hostile
error message, the oops function can display a nice web page explaining
that something has gone wrong, and/or email the webmaster that something
went awry, etc. [This was originally from one of the O'Reilly Perl books,
but I can't remember which one.]
</tip>
More information about the thelist
mailing list