in reply to Re: Printing that "waiting" page or call it win32::process::create problem
in thread Printing that "waiting" page or call it win32::process::create problem

Thanks fglock,
How come whatever is printed by that waiting.pl script never gets to the user ?

Let'say I just want to print some HTML with waiting.pl. How come it never makes it to the user's browser ?
################## # # waiting.pl # ################## ... print "Content-type: text/html\n\n"; print "You are waiting.... aren't you ?"; exit;
  • Comment on Re: Re: Printing that "waiting" page or call it win32::process::create problem
  • Download Code

Replies are listed 'Best First'.
Re: Re: Re: Printing that "waiting" page or call it win32::process::create problem
by blssu (Pilgrim) on Sep 27, 2002 at 20:30 UTC

    IIRC, Win32 processes do not inherit open files like Unix does. That means when you create the "waiting" sub-process, it won't have a connection to the user's browser.

    What you probably want to do is simply turn off caching in the web server (for this page only). What normally happens is the web server intercepts all of the data you are generating and sends it back to the user's browser for you. If you tell the web server not to do this -- your script is taking direct control of sending data -- the browser will see text as soon as you send it. (Don't forget that Perl will also cache your output! See $| for details.) You may need frames, JavaScript or some "meta" refresh tags to get the user interface you want.

Re: Re: Re: Printing that "waiting" page or call it win32::process::create problem
by fglock (Vicar) on Sep 27, 2002 at 17:37 UTC

    exit;

    You don't need to "exit" a CGI script. I don't know if this is the problem, but it might be.