sigmazero13 has asked for the wisdom of the Perl Monks concerning the following question:
What happens is that it displays on the client everything up to and including the "visible page headers" stuff, but none of the values. However, when I set $| = 0 for the STDOUT one, it prints everything and then does the processing. Am I misunderstanding how $| works?$| = 1; select(STDERR); $| = 1; select(STDOUT); $| = 1; print <<END_HTML; Content-type: text/html \n\n <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <head> END_HTML #reads the input values here print END_HTML; <title>PAGE TITLE</title> <!--OTHER HTML HEADER STUFF--> </head> <body> <!--VISIBLE PAGE HEADINGS AND STUFF--> END_HTML print "value: $value<br>"; # the above line is repeated for each input value open(temp_handle, "> log_file"); print(temp_handle "log stuff"); #repeated with information close temp_handle; system("external_program"); # the above program can take several seconds to several # minutes to run print <<END_HTML; </BODY> </HTML> END_HTML
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: I think I'm misunderstanding $|
by shmem (Chancellor) on Dec 17, 2007 at 22:42 UTC | |
by sigmazero13 (Novice) on Dec 17, 2007 at 22:46 UTC | |
by ikegami (Patriarch) on Dec 17, 2007 at 22:49 UTC | |
|
Re: I think I'm misunderstanding $|
by friedo (Prior) on Dec 17, 2007 at 22:44 UTC | |
by sigmazero13 (Novice) on Dec 17, 2007 at 22:59 UTC | |
|
Re: I think I'm misunderstanding $|
by ikegami (Patriarch) on Dec 17, 2007 at 22:45 UTC | |
by sigmazero13 (Novice) on Dec 17, 2007 at 22:57 UTC | |
by ikegami (Patriarch) on Dec 17, 2007 at 23:11 UTC | |
by sigmazero13 (Novice) on Dec 17, 2007 at 23:20 UTC | |
by ikegami (Patriarch) on Dec 17, 2007 at 23:45 UTC | |
| |
by shmem (Chancellor) on Dec 18, 2007 at 10:41 UTC | |
by quester (Vicar) on Dec 18, 2007 at 08:14 UTC | |
|
Re: I think I'm misunderstanding $|
by andye (Curate) on Dec 18, 2007 at 20:45 UTC |