Monday, March 30, 2015

Python Simple Web Crawler

A web crawler (also known as a web spider or web robot) is a program or automated script which browses the World Wide Web in a methodical, automated manner and this process is called Web crawling or spidering.

Simple Program For Web Crawler...
import urllib2
from urllib2 import urlopen

website = 'https://google.com'

sourceCode = urllib2.urlopen(website).read()
print sourceCode

This Program will capture the Source Code of the given URL and print on the Python Shell. In this way, You extract the information from the website. In next post, we will discuss about that.