0755mx 发表于 2015-5-28 09:48:35

Windows 下的FTP脚本

      ftp -n -s:ftp.txt xxx.xxx.xxx.xxx
  其中-n表示只连接到服务器而不提示登录。-s:ftp.txt表示连接成功后执行ftp.txt内的ftp命令,xxx.xxx.xxx.xxx是服务器的ip地址。
  那么这个ftp.txt如何写呢?如下:
      user {username} {password}
    cd backup
    get file1
    get file2
    bye
  其中{username}和{password}表示登录ftp服务器的用户名和密码。登录后用get命令将两个文件下载下来。
页: [1]
查看完整版本: Windows 下的FTP脚本