python urlopen via file code example
Example 1: urllib urlretrieve python 3
#In Python 3.x, the urlretrieve function is located in the urllib.request module:
from urllib.request import urlretrieve
Example 2: python get an online file
import urllib2 # the lib that handles the url stuff
data = urllib2.urlopen(target_url) # it's a file like object and works just like a file
for line in data: # files are iterable
print line