Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^3: How a web server sending data to a CGI perl script ?

by Anonymous Monk
on Jan 25, 2016 at 07:26 UTC ( [id://1153540]=note: print w/replies, xml ) Need Help??


in reply to Re^2: How a web server sending data to a CGI perl script ?
in thread How a web server sending data to a CGI perl script ?

$ cat shabba for my $key ( grep /perl/i , keys %ENV ){ print qq{ $key $ENV{$key}\n} +; } $ perl shabba PERL_MB_OPT --config installhtmldir= --binhtml= $ perl -e " $ENV{PERL_SHABBA}=666; system $^X, q{shabba}; " PERL_SHABBA 666 PERL_MB_OPT --config installhtmldir= --binhtml= --config installht +mldir= --binhtml= $ perl shabba PERL_MB_OPT --config installhtmldir= --binhtml=

Replies are listed 'Best First'.
Re^4: How a web server sending data to a CGI perl script ?
by exilepanda (Friar) on Jan 26, 2016 at 17:00 UTC
    Oh Wow!! Surprised!!! Great demonstration and works perfectly! And I just notice the system() or the backticks ( the right tool for my case ) are actually kind of fork thing... which is the "how" that I exactly asking! Thanks man!

    Though.. what still puzzle me is how do you leave the <STDIN> open for the CGI to read() in this code pattern ?

      Its not a pattern, just shows %ENV is inherited from parent process

      Its one part of what HTTP::Request::AsCGI does, STDIN... stuff is the other part

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (6)
As of 2024-03-28 22:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found