Socket python (Modul urllib)

Sedikit contoh dari salah satu modul urllib yang terdapat pada python
  
import urllib
print "========================================="
print " C0d3 5can 53rv3r "
print " C0d3 By 54v0y "
print "========================================="
print " ex : http://hmif.org "
prompt = "Masukkan URL Anda : "
url=raw_input(prompt)
try:
data=urllib.urlopen(url)
for header in data.headers.headers:
print header
except:
print "Masukkan URL Anda ex: http://hmif.org"

Simpan dengan nama apa saja dengan ekstension .py contoh url.py
lalu jalan ken dengan cara
$python urllib.py
Socket python (Modul urllib) Socket python (Modul urllib) Reviewed by Unknown on 10:00 AM Rating: 5
Editor By 54v0y. Powered by Blogger.