Re: Debug question




Paul Lalli wrote:
JoeyP wrote:
I am accessing a (perl)CGI script from an HTML doc. Something is
blowing up in the CGI.
How do I send an 'alert' pop-up message while in the CGI?

You don't. If something is "blowing up" in the CGI program, that
program is not going to correctly create an HTML document that the
browser can render. It is the browser's own Javascript that would
process the alert box.

I tried print " alert("Error"); "; but that didn't work.

Not surprising...

I am new to perl.

The problem has nothing to do with Perl and everything to do with CGI.
You seem to have a fundamental lack of understanding about what a CGI
program is.

If your Perl program is malfunctioning, you need to look at the error
output and see why it's malfunctioning. Either look in the CGI
server's error log, or put this statement near the top of your program,
right after 'use CGI;'
use CGI::Carp qw/fatalsToBrowser/;

Paul Lalli

Thanks a bunch Paul.

use CGI::Carp qw/fatalsToBrowser/; worked.

Thanks

.



Relevant Pages

  • Re: Debug question
    ... blowing up in the CGI. ... How do I send an 'alert' pop-up message while in the CGI? ... server's error log, or put this statement near the top of your program, ...
    (comp.lang.perl.misc)
  • Debug question
    ... blowing up in the CGI. ... How do I send an 'alert' pop-up message while in the CGI? ...
    (comp.lang.perl.misc)
  • Re: CGI not novel, instant CAI gratification is garbage (was: JDEE/CGI/flashcards ...)
    ... > to as CGI applications or more correctly CGI based applications. ... is not spam it sends some kind of alert across the ... current alert level is, and when I log in it tells me what the current ...
    (comp.lang.lisp)
  • Re: Form Data to File
    ... Paul Lalli wrote: ... "normal" ways of using the CGI module. ... Here you're declaring a new CGI object, and you start printing out the ... Your HTML form isn't actually calling this script at all. ...
    (perl.beginners)
  • Re: Take three form variables and write to an "settings-file"
    ... Paul Lalli wrote: ... >>textfields and put them in an local file on the webserver. ... >>This information is later on used in shell scripts running on the server. ... > Have you ever done any CGI programming with Perl? ...
    (comp.lang.perl.misc)