LMPX.COM |
Home | Linux | Mysql | PHP | XML | ||
|
|
|||
From: Terrence Brannon Date: Tue May 18 04:12:13 2004 Subject: Re: FTP->Binary
PerlDiscuss - Perl Newsgroups and mailing lists wrote: >I am trying to get my program to switch to Binary mode. I know the command >is ftp->binary();, however, it does not work. > where in the Net::FTP docs does it say that? I don't think you will find it. > By chance, i got the program >to work only when i have the following lines of code inserted: >$bin=$ftp->binary or die "Can not change the Type to Binary\n"; >$bin=$ftp->binary; > >If I take out any of those lines it transfers in Ascii mode. Why? > > I think the server can default to ascii or binary. But then it can be changed. >Thanks >Isaac > > > > You can set the default server transfer type when you create $ftp also... perldoc Net::FTP for more details: $net = Net::FTP->new($host, { Type => 'I' } ); #for example, untested -- mathematics: the science of quantity, shape, and arrangement computersci: the science of information description and transformation liberalarts: essential study for adequate education and civic participation.
| Navigate in group perl.libnet at sever nntp.perl.org | |
| Previous | Next |
| © No Copyright You are free to use Anything |
Site Maintained by PHP Developer
Powered By PHP Consultants |