How to grab a part of web page?

Gerhard Häring gerhard.haering at gmx.de
Tue Jul 9 23:14:35 EDT 2002


* William Park <opengeometry at NOSPAM.yahoo.ca> [2002-07-09 22:31 +0000]:
> A <printers at sendme.cz> wrote:
> > Hi,
> > Is it possible to download only a part of web page?
> > Say I need to find out an information about a customer that starts 
> > at 1500 byte position and ends at 2000 byte position. If the whole 
> > page has about 100 kb it seems to me waste of time to load all the 
> > page.
> > What is the best, yet easy, solution?
> > Is it possible to use httplib or necessary socket module?
> > Thank you for help.
> > Ladislav
> 
> I think it's possible.  When I use 'wget -c' to download HTML, sometimes I
> see it start from an offset, rather than from the beginning.

Doing this while having a packet sniffer running showed me what the
corresponding HTTP header is.

Gerhard
-- 
This sig powered by Python!
Außentemperatur in München: 17.6 °C      Wind: 1.7 m/s





More information about the Python-list mailing list