Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- import urllib2, sys
- urlstr = sys.argv[1]
- fname = urlstr.split('/')[-1]
- response = urllib2.urlopen(urlstr)
- f = open(fname, "w")
- f.write(response.read())
- f.close()
- print "written " + fname
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement