This simple plugin adds an HTML (Not XML) sitemap of your pages (not posts) by entering the shortcode [html_sitemap] in the page content. This simple plugin is configured with the
[html_sitemap] shortcode. This plugin can display a sitemap with specific depths, from a specific parent page and include/exclude specific children. Shortcode attributes include
post_status, everything the
wp_list_pages function accepts. In addition to the
wp_list_pages options you can also set
This plugin is perfect for those who use WordPress as a CMS.
Please see documentation for the
wp_list_pages for a complete list of options.
The following options may be configured in addition to options documented in
id attributes may specified set class or id values for the initial HTML Page Sitemap
<ul> list tag.
child_of attribute value can be a numeric page ID (integer), or use the custom value CURRENT or PARENT. The value “CURRENT” will use the current page’s ID. The value “PARENT” will uses the curent page’s parent ID.
ordered_list_type attribute is an HTML Page Sitemap plugin exclusive option for specfiying an ordered list type. Not setting a ordered_list_type will use an unordered list (default).
ordered_list_type="1"– The list items will be numbered with numbers
ordered_list_type="A"– The list items will be numbered with uppercase letters
ordered_list_type="a"– The list items will be numbered with lowercase letters
ordered_list_type="I"– The list items will be numbered with uppercase roman numbers
ordered_list_type="i"– The list items will be numbered with lowercase roman numbers
Note: This plugin only works with Hierarchical Custom Post Types. This plugin will not work if your post type is not heirarchical.
First example shows how to add a sitemap for the entire site.
Example shortcode will add a sitemap to a page displaying a depth limit of 3 and exclude page ID 708.
[html_sitemap depth=3 exclude=708]
Example shortcode will add a sitemap to a page displaying only children and grandchildren of the current page.
[html_sitemap depth=2 child_of=CURRENT]
Example shortcode will add a sitemap to a page displaying children and grandchildren of the parent page (would include the curent page as well).
[html_sitemap depth=2 child_of=PARENT]
Example shortcode will add a sitemap displaying the page modified date with the pages sorted by the menu order number.
[html_sitemap show_date=modified sort_column=menu_order]
Example shortcode excluding multiple pages with ids 708, 1024 and 42.
Example shortcode will add a class attribute to the
Example shortcode will add an id attribute to the
Example shortcode will display an ordered list using lowercase letters with a depth of 1.
[html_sitemap ordered_list_type="a" depth=1]
For the latest information visit the website.
ATTENTION: HTML-SITEMAP SHORTCODE HAS CHANGED
html-sitemap still works, the new HTML Sitemap shortcode is
html_sitemap. The dash/hyphen may not get processed correctly if other plugins use the same prefix such as the Syntax Highlighter plugin. read more, and more
Follow us on Twitter
- Why is there no settings page for the plugin?
I put together this plugin in less than 2 hours, this readme.txt actually took longer to create. This plugin is meant to be simple and easy to use. To keep it simple, it doesn’t add settings to your database or clutter to your admin screens.
I felt the need to post a quick review for this plugin since it got a couple low ratings due to only including pages. The plugin clearly states it is for listing all of your pages only. It is not a normal XML sitemap. I'm giving it 5 stars because it is simple and does what I wanted. I simply wanted a page that listed all of my site's pages. This did it quickly and minimally. I do have one suggestion for the author. Rename the plugin. Instead of HTML Page Sitemap, perhaps it should be Simple Page List. Or, something that does not include "sitemap" since that word is what caused the couple low reviews, I think.
If you only have pages on your website and no blogs is fine.
...But if you have blogs on your website look for another plugin.
Thanks for the share anyway.
- Released on 11/24/2015
ordered_list_typeoption to use an ordered list rather than unordered. (Thanks Allie for the feature suggestion!)
- Tested with WordPress 4.4 beta 4
- Released on 9/15/2015
- Tested with WordPress 4.3.
- Added class and id attribute options for specifying HTML class and/or id attributes in the unordered list
<ul>. (Thanks phorbidden for the feature suggestion!)
- Updated readme, added additional examples for the class and id attribute options.
- Released on 1/11/2015
- Tested with WordPress 4.1.
- End of source no longer includes closing PHP tag as recommended by WordPress.
- Updated readme, added additional example excluding multipe pages.
- Released 3/11/2013
- HTML Sitemap compatible with latest versions of WordPress up to 3.5.1
- Nothing has changed with this plugin other than the readme.txt.
- Released 1/31/2012
- Hyphen in shortcode changed to underscore.
htmlsitemapshortcodes work. read more here
- HTML Sitemap compatible with latest versions of WordPress up to 3.3.1
- Released 6/27/2010
- HTML Sitemap compatible with latest versions of WordPress 2.9 and 3.0.
- Released on 11/24/2009
- Fixed typos in readme
- Added child_of options
** child_of=CURRENT (starts list of pages that are children of the current page)
** child_of=PARENT (starts list of pages that are of the same level as current page)
- Released on 09/05/2009
- Initial release of HTML Page Sitemap plugin.