s9************@yahoo.com (mike) wrote in message news:<df**************************@posting.google. com>...
$telnetcmd << "EOF";
perl -ne "chdir(/tmp); while ($file = <*.txt>) { print stat($file); }"
EOF
print $telnetcmd;
it give me some errors:
syntax error at ./test.pl line 3, near "-ne"
Semicolon seems to be missing at ./test.pl line 3.
Execution of ./test.pl aborted due to compilation errors.
what is wrong with the code...?? thanks
You meant:
$telnetcmd = << "EOF";
Actually I suspect you didn't what $file interpolated so you meant:
$telnetcmd = << 'EOF';
Actually, come to think of it, if you don't like wasting your time
hunting down obscure bugs, you probably should have said:
use strict;
use warnings;
my $telnetcmd = << 'EOF';
This newsgroup does not exist (see FAQ). Please do not start threads
here.