Skip to main content

Common lib used by Dipoankar

Project description

Example of code:
from pydipankar import Spider

res =[]
for i in range(1,4):
url = 'http://www.geeksforgeeks.org/category/matrix/page/%s/'%i
soup = Spider.buildSoup(url);
res += Spider.getAttrListForXPath(soup,'div#content article',None,{'entry-title':['.entry-title a','text'],'entry-summary':['.entry-summary','text']})

f = open('a.txt','w+')
ii =0
for r in res:
ii = ii+1
f.write(str(ii) +'. '+r.get('entry-summary')[0].encode('utf-8').strip()+'\n\n\n')
f.close()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pydipankar, version 1.0
Filename, size File type Python version Upload date Hashes
Filename, size pydipankar-1.0.tar.gz (2.3 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page