1

I was trying to run the following script in command line in windows xp but I couldn't make it :

C:\..\ftp  -s:"%~f0"&GOTO:EOF
open someweb.com
username
password
pwd
bye

the following runs ok:

ftp>@ftp -i -s:"%~f0"&GOTO:EOF
open someweb.com
username
password
pwd
bye

but I am trying to achieve it with command line. Is there a way to do so?

1 Answer 1

3

You can’t do it directly on the command line, but you can use the command line to build a file that you can send as input to ftp:

C:\>echo open someweb.com >input
C:\>echo next ftp commmand >>input
C:\>echo another ftp commmand >>input
C:\>ftp -i <input

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .