Ruby 设置 FTP 传输模式为 Passive

2014-11-29 0 879
Ruby 设置 FTP 传输模式为 Passive
require 'net/ftp'

ftp = Net::FTP.new('ftp.ruby-lang.org')
ftp.passive = true
ftp.login(username, password)

ftp.delete(filename)

ftp.list('*') { |file| puts file }
ftp.close

遇见资源网 ruby Ruby 设置 FTP 传输模式为 Passive http://www.ox520.com/16196.html

常见问题

相关文章

发表评论
暂无评论
官方客服团队

为您解决烦忧 - 24小时在线 专业服务