in reply to (Kozz) Re: "canned" FTP
in thread "canned" FTP
While the node referenced above deals more specifically with the usage of Net::FTP (which I believe would offer a much cleaner and compact solution in this case), PASV behaviour as discussed in the above node can be initiated within a FTP session through the issuing of the command PASV prior to any commands which make use of the ftp-data connection (eg. LIST).
Using the code in question as a base ...
- print FTP "PASS password\r\n"; sysread (FTP, $FormData, 1024); print STDOUT "$FormData\n"; print FTP "PASV\r\n"; sysread (FTP, $FormData, 1024);
Just on a final note, you know that by introducing sysread in the manner that you have, you have also introduced some very nasty buffer dependencies in your code - This in itself could cause a number of headaches as your code is moved into production.
perl -e 's&&rob@cowsnet.com.au&&&split/[@.]/&&s& .com.&_&&&print'
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Re: (Kozz) Re: "canned" FTP
by PriNet (Monk) on Feb 21, 2002 at 03:33 UTC | |
by petral (Curate) on Feb 21, 2002 at 13:19 UTC |