Re: Debug question



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

.



Relevant Pages

  • Re: Debug question
    ... Paul Lalli wrote: ... blowing up in the CGI. ... How do I send an 'alert' pop-up message while in the CGI? ...
    (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: Perl and IIS - script runs but The page cannot be displayed
    ... Look at the server's error log. ... Run the script from a command prompt so you can see ... The FAQ answer points to brian d foy's CGI "Troubleshooting Perl CGI ...
    (comp.lang.perl.misc)
  • Re: perl LibXML
    ... as binary or rpm|deb|pkg package? ... there seems to be an older version of libxml2, namely 2.4.x, and for some ... Try to make sure the cgi finds the newer version of the lib instead of the ...
    (comp.lang.perl.misc)