in reply to Constructing STDIN for an external progam
You want to read perlopentut. That should answer your questions. Specifically, I think you don't want system but instead want to open the external command with a leading pipe.
open(PRINTER, "| lpr -Plp1") || die "can't run lpr: $!"; print PRINTER "stuff\n"; close(PRINTER) || die "can't close lpr: $!";
However, you'll also want to read perlsec.
Cheers,
Ovid
New address of my CGI Course.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Constructing STDIN for an external progam
by Thelonius (Priest) on Sep 11, 2006 at 15:24 UTC | |
by ikegami (Patriarch) on Sep 11, 2006 at 17:27 UTC |