WinコマンドでFTP?

■ファイル名:ftpup.bat
@ECHO OFF
ftp -s:ftpup.scr > ftpup.log

■ファイル名:ftpup.scr

open [ホスト名:www.xxx.xxx]
[ユーザ名:usernae]
[パスワード:passwd]
binary(転送モード
put C:¥usr¥test.txt (←転送するファイル¥は半角で^^;
quit

あとはftpup.scrが実行されれば、ftpup.logが生成される

ftp> Connected to (指定ホスト名).open (指定ホスト名)
220 FTP Server ready.
User ():
331 Password required for tracefile.
230 User tracefile logged in.
ftp> binary
200 Type set to I
ftp> put C:\usr\test.txt
200 PORT command successful
150 Opening BINARY mode data connection for test.txt
226 Transfer complete.
ftp: 1428 bytes sent in 0.00Seconds 1428000.00Kbytes/sec.
ftp> quit
221 Goodbye.
その他の詳しいコマンドについては。下記
[以下引用]
http://ykr414.com/dos/dos03.html#02

Trackback URL

Leave a Reply