Web Development Tools that Enlighten
Dynamic Site Map with PHP
This is a script, written in PHP, that will generate a site map based on the directory structure of the site. You can easily exclude files and/or directories.
How it works
The script functions by recursively calling itself to traverse the directory
tree starting at the site's root directory. It gets the file title from
each file on the site and displays the page title, with a link to the file.
Note that the script obtains the title of the page by extracting the text between
the opening and closing
<title> tags. That means that it
only works on pages that exist (not all the variations that can be generated)
and where the title is static and contained in the page.
As you might imagine, this makes the script rather processor intensive. However, for smaller sites, it doesn't present much of a problem. I've used the script on a site of around 500 pages and it has a slight delay, but not so much as to be objectionable.
For larger sites or sites where the number of pages and their titles don't change frequently, you can run the script once on your development machine, then view the browser's source code and paste the result into a static page. That eliminates the processor load, but does require you to manually update the site map each time you add, delete, or rename a page.
You can download the files necessary. Configuration is easy. See the readme.txt file included in the ZIP file for details.