extracting <h1> element for TOC
| From: | Chris Komlenic | Date: | Sat, 30 Jun 2001 07:59:38 +0000 |
| Subject: | extracting <h1> element for TOC | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-55649@lists.php.net to get a copy of this message | ||
I have a directory with many small html files...which I'd like to return the
text within the <h1> tags for the purpose of creating a table of contents
(TOC).
I currently have a script which reads the directory, and returns all the
files which I'd like to open. I'm a bit lost on how to write a loop which
would open each file, and return the info within <h1> tags.
How could this best be accomplished?
Thanks in advance.
Chris