CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
'command not implemented' ftp put

 



Spence32
New User

Oct 15, 2008, 5:26 AM

Post #1 of 3 (422 views)
'command not implemented' ftp put Can't Post

Hi,

I am using 'ftp put' to push files to a remote server, but each time an error is returned 'command not implemented.'. Anyone know what this means or how to fix it?

Here is the code:

foreach my $file (@putFiles)
{
if ($file ne '.' && $file ne '..' )
{
$ftp->put($file) or print LOGFILE "$trgt_dir\\$file:".$ftp->message();
}
}

Thanks

Code



      
    


sycoogtit
User

Oct 15, 2008, 6:40 AM

Post #2 of 3 (421 views)
Re: [Spence32] 'command not implemented' ftp put [In reply to] Can't Post

What's $ftp? I think we need to see more code.

--
http://bunsooter.com


KevinR
Veteran


Oct 15, 2008, 11:22 AM

Post #3 of 3 (418 views)
Re: [Spence32] 'command not implemented' ftp put [In reply to] Can't Post

You're trying to use a command that is not supported on that FTP server.

Side note, this is wrong:


Code
 if ($file ne '.' && $file ne '..' )


Should be:


Code
 if ($file ne '.' || $file ne '..' )


Your way means both conditions must be true. So $file has to not equal . and .. in order to be true.
-------------------------------------------------

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives