import urllib.request, urllib.parse, urllib.error
fhand= urllib.request.urlopen('http://sampleurl.com/sampledoc.sample')
for line in fhand:
    print(line.decode().strip())
#replace sample url section with your url in which you wish to navigate to
