LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   General (https://www.linuxquestions.org/questions/general-10/)
-   -   FTP script (https://www.linuxquestions.org/questions/general-10/ftp-script-397395/)

the_imax 12-28-2005 08:30 PM

FTP script
 
I have been trying to run a ftp btach script in windows
I am using the following synthax

Code:

open ftp.myserver.com
myUserName
MyPassword
cd public_html
dir
lcd desktop
get file.php
bye

but I always get a Authentication failed error, can anyone tell me the reason for this ?
The same password and username are working fine If a use a FTP client.
Thanks

scuzzman 12-29-2005 12:19 AM

This should help a bit as the Windows implementation of wget can use FTP just like the Linux one:
http://forums.windowsforum.org/index...=19064&hl=wget

the_imax 12-29-2005 08:17 PM

Quote:

Originally Posted by scuzzman
This should help a bit as the Windows implementation of wget can use FTP just like the Linux one:
http://forums.windowsforum.org/index...=19064&hl=wget

Thanks but this does not solve my problem :(

scuzzman 12-29-2005 11:06 PM

Did you try it? It should work exactly as you need.

the_imax 12-29-2005 11:27 PM

Basically I want to know if there is any problem with the command syntax that I am using ?
as according to this http://support.microsoft.com/?kbid=96269 MS article the script should work flawlessly

scuzzman 12-30-2005 01:22 AM

Ok - I just realized what you were doing, and you're missing only one line. The proper script should be:
Code:

open ftp.myserver.com
user
myUserName
MyPassword
cd public_html
dir
lcd desktop
get file.php
bye

Note the missing 'user' line - that must be there.

the_imax 12-30-2005 01:27 AM

I had tried it with the user line , it does not make any difference .

( Basically you need the 'user ' part if you have automatic login disabled at he remote host )


All times are GMT -5. The time now is 12:35 AM.