Getting source code from frames using urllib

Rene Pijlman at de.nieuwsgroep
Thu Feb 27 08:36:17 CET 2003

>My current problem is trying to figure out how to retrieve the source
>code of a webpage that uses frames.
><html><head><title>Some title </title></head>
><frameset rows='120,*' border='5' frameborder='5' framespacing='5'>
><frame name='top' src='top.html' scrolling='no'>
>How would I, using this example get the html source of the frame named

Use the HTMLParser module to parse the HTML file. Override
handle_starttag() to act on the <frame> tags.

René Pijlman

Wat wil jij leren?

More information about the Python-list mailing list