[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cgiapp] Re: A bit off topic - CGI:Application and CGI::Carp


In article <suppressed>, Irubin Consulting wrote:
> Hello,
> 
> I am trying to write an error handling routine, so that the errors from my
> CGI::Application are displayed in the browser. I have set a runmode of
> 'error500' which is called by default every time a 500 error occurs (via
> ErrorDocument in the .htaccess files). Below is the code for that runmode.
> 
> How can I also display the exact error as formatted by CGI::Carp (and not
> just "Premature end of script headers"). Is this possible?

Yes. Send the Carp output to STDERR or an error log. To access it,
read in the last 50 lines or so of that error log and display them in
the browser.

I have been doing something like that on our development web server for
a while and it works fairly well. 

	Mark

-- 
 . . . . . . . . . . . . . . . . . . . . . . . . . . . 
   Mark Stosberg            Principal Developer  
   suppressed     Summersault, LLC     
   765-939-9301 ext 202     database driven websites
 . . . . . http://www.summersault.com/ . . . . . . . .


---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/suppressed/
              http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.