Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Running Command Line Programs from a CGI Script

by mda2 (Hermit)
on Jun 13, 2005 at 02:00 UTC ( #466030=note: print w/replies, xml ) Need Help??


in reply to Running Command Line Programs from a CGI Script

Some years ago I had a similar problem with random sendmail problems. To solve it I tried put header first, but the response is redirect stderr. (Previous sugest by Solo)

Some time after I think again about and concludes with separated buffers handled by apache web server...

When your command-line binary end, flush STDERR, before your STDOUT flushed by your cgi.

Today I like to put three lines on start my codes...

  • use strict;
  • use warnings; (or -w at shebang line)
  • $|++; # (Update: auto flush handles, like autoflush call on IO::Handle)

    --
    Marco Antonio
    Rio-PM

    • Comment on Re: Running Command Line Programs from a CGI Script
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Node Status?
    node history
    Node Type: note [id://466030]
    help
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others romping around the Monastery: (5)
    As of 2019-12-15 04:38 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      No recent polls found

      Notices?