html parser?

Christoph Söllner christoph.soellner at web.de
Tue Oct 18 06:41:05 EDT 2005


Hi *,

is there a html parser available, which could i.e. extract all links from a 
given text like that:
"""
<a href="foo.php?param1=test">BAR<img src="none.gif"></a>
<a href="foo2.php?param1=test&param2=test">BAR2</a>
"""

and return a set of dicts like that:
"""
{
  ['foo.php','BAR','param1','test'],
  ['foo2.php','BAR2','param1','test','param2','test']
}
"""

thanks,
Chris 





More information about the Python-list mailing list