ASCII file download : Ftp : Network PYTHON TUTORIALS


PYTHON TUTORIALS » Network » Ftp »

 

ASCII file download


from ftplib import FTP

def writeline(data):
    fd.write(data + "n")

f = FTP('ftp.kernel.org')
f.login()

f.cwd('/pub/linux/kernel')
fd = open('README', 'wt')
f.retrlines('RETR README', writeline)
fd.close()

f.quit()



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo Network
» Ftp