Re: Ask how to use HTMLParser

2010-01-10 Thread Nobody
On Fri, 08 Jan 2010 11:44:48 +0800, Water Lin wrote: I am a new guy to use Python, but I want to parse a html page now. I tried to use HTMLParse. Here is my sample code: -- from HTMLParser import HTMLParser Note that HTMLParser only tokenises HTML; it doesn't actually

Re: Ask how to use HTMLParser

2010-01-08 Thread h0uk
div class=secttlbar div class=lf secttl span id=thread_subject_site Ask how to use HTMLParser /span

Re: Ask how to use HTMLParser

2010-01-08 Thread Dave Angel
Water Lin wrote: h0uk vardan.pogos...@gmail.com writes: On 8 янв, 08:44, Water Lin water...@ymail.invalid wrote: I am a new guy to use Python, but I want to parse a html page now. I tried to use HTMLParse. Here is my sample code: -- from HTMLParser import

Ask how to use HTMLParser

2010-01-07 Thread Water Lin
I am a new guy to use Python, but I want to parse a html page now. I tried to use HTMLParse. Here is my sample code: -- from HTMLParser import HTMLParser from urllib2 import urlopen class MyParser(HTMLParser): title = is_title = def __init__(self, url):

Re: Ask how to use HTMLParser

2010-01-07 Thread h0uk
On 8 янв, 08:44, Water Lin water...@ymail.invalid wrote: I am a new guy to use Python, but I want to parse a html page now. I tried to use HTMLParse. Here is my sample code: -- from HTMLParser import HTMLParser from urllib2 import urlopen class MyParser(HTMLParser):    

Re: Ask how to use HTMLParser

2010-01-07 Thread h0uk
On 8 янв, 08:44, Water Lin water...@ymail.invalid wrote: I am a new guy to use Python, but I want to parse a html page now. I tried to use HTMLParse. Here is my sample code: -- from HTMLParser import HTMLParser from urllib2 import urlopen class MyParser(HTMLParser):    

Re: Ask how to use HTMLParser

2010-01-07 Thread Water Lin
h0uk vardan.pogos...@gmail.com writes: On 8 янв, 08:44, Water Lin water...@ymail.invalid wrote: I am a new guy to use Python, but I want to parse a html page now. I tried to use HTMLParse. Here is my sample code: -- from HTMLParser import HTMLParser from urllib2 import