Hello exilepanda,
If you do it the way I described, the %ENV variables are already set-up for you. Do not touch the %ENV, but copy the %ENV to a temp hash. And remember you still need the GET / POST data ( the actual $Todo work ) from the WebServer. ( Example ).
Now the second client has the environment of the WebSever, and it's own %ENV from Perl. The processing client uses %TempENV for WebServer info and it's own %ENV if it needs it.my $Todo = ...; # Data sent via GET or POST from browser via We +bServer my $environment = ''; foreach my $env ( keys %ENV ) { $environment .= "$env\t$ENV{$env}\n"; } my $send = pack("N",length($environment) ) . $environment . pack( +"N",length($Todo) ) . $Todo; my $ret = send_data( $svr, \$send ); # Send to processing Perl s +cript
It's clean and you don't have to get into the error handling of the WebServer.
Good Luck!
Regards...Ed
"Well done is better than well said." - Benjamin Franklin
In reply to Re^3: How a web server sending data to a CGI perl script ?
by flexvault
in thread How a web server sending data to a CGI perl script ?
by exilepanda
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |