HTML Table-of-Content Extraction Script



I'm looking for a function which extracts a table of contents of HTML file(s) from <Hx....><a name=...></a>...</Hx> and possibly auto-creates the ancors.
Maybe something already exists?


Robert
.