Posted by Peter Palfrader aka Weasel on 1999-10-11
On Mon, Oct 11, 1999 at 10:08:49PM +0200, Frank Hale wrote:
> Howcome the die command doesn't work in a browser when
> you execute a cgi? How would I implement the same
> thing for a cgi?
>
> All I get is "Document contains no data" errors when
> infact it should execute the die command and print a
> message.
>
It does work. However since it does not print a "content-type" header,
the server/browser generates an error.
You can either print the header prior to calling die or install an
event handler with something like
$SIG{'__DIE__'} = {
print "content-type: text/plain\n\n";
print "<censored>: $1";
};
at the start of your script. Check out my code2html or the ckb.pl or
the webinterface I sent you. All of them include such an error
handler.
--
Weasel http://www.cosy.sbg.ac.at/~ppalfrad/
PGP encrypted messages prefered. See my site or finger -l ppalfrad
A friend is someone who knows the song in your heart and
can sing it back to you when you have forgotten the words.
Date: Mon, 11 Oct 1999 18:51:38 -0300
From: "Dario Silva" <tripero@xxxxxxxx.xxx>
Subject:
Hi everybody!! This is, I think, the first time I send you a mail; I
read every day the digest I'm receiving and now I am the person who ask
(forgive me for my pseudo-english)
The question is: how can a win32 aplication be notified when a
connection to the web has been established?? (and when it has been
finished).
That's all, I think I might use some win message but I'm starting with
this staff (I mean, "net apps") so I'd like to learn more about that (I use
Delhpi and C Builder)
I hope any of you can give me some help.. Thank you all!!!
Previous post | Next post | Timeline | Home