On 27 juin, 16:38, [EMAIL PROTECTED] (Oryann9) wrote:
> --- Octavian Rasnita <[EMAIL PROTECTED]> wrote:
>
> > Hi,
>
> > You need to use:
>
> > $ftp->get("/path/to/remote/file",
> > "/path/to/local/destination_file");
>
> > Octavian
>
> Also you can use
>
> $remotedir = qq(/path/to/remoteserver/dir/);
> $sftp->cwd($remotedir) || die "CWD to folder outbound
> failed!: $!",
>
> ## OHMONSTER here is the remote file
> foreach ( $sftp->ls() ) {
> if (/${$fref}\d+\w+/) {
> $OHMONSTER = $_;
> $sftp->get( $OHMONSTER, "$localdir/$OHMONSTER" )
> || die "SFTP get from xxxx.com failed!: $!",
>
> ____________________________________________________________________________________
> Food fight? Enjoy some healthy debate
> in the Yahoo! Answers Food & Drink
> Q&A.http://answers.yahoo.com/dir/?link=list&sid=396545367
>
> ____________________________________________________________________________________
> Building a website is a piece of cake. Yahoo! Small Business gives you all
> the tools to get online.http://smallbusiness.yahoo.com/webhosting
Octavian Rasnita > Ok I really don't get it.
My folder tree is similar to that one: d:\shared\exports\Export.csv
When I connect to the sFTP server, the home directory is the "shared"
folder, so when I list the folders I see the "exports" one.
I tried:
$sftp->get("exports/Export.csv", local/folder/file.csv);
$sftp->get("/exports/Export.csv", local/folder/file.csv);
$sftp->get("shared/exports/Export.csv", local/folder/file.csv);
$sftp->get("/shared/exports/Export.csv", local/folder/file.csv);
But neither of these work :(
oryann9 > the cwd command does not exists with sFTP package :((
It'd have been to easy !
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/