Site Map to a Page from Specific Folder and Depth documentation for the dotCMS Content Management System

This macro has been deprecated, use the navtool to build your sitemap.

Use this macro if you want to add a site map to your page from a specific path. You can specify how many levels from the folder path specified that the sitemap should start and end on.

Macro Overview:

Syntax:

#siteMapFolder(2,2,"/folder1/myFolder")

Arguments:

  • startLevel
    This is number of folders the map should start at from the path.
  • depth
    This is how many folders to drill inside of from the start depth.
  • path
    This is the path to the folder to start at.
  • Optional Parameters:
  • reverseOrder (velocity variable not a parameter)
    Set this boolean to true to return the Site Map ordered descending. Default: false.
  • showHome
    Set to true if you want to display a link to Home Page
  • siteMapIdPrefix
    Prefix to be prepend to every id on the generated sitemap.

Examples:

Example 1: A simple example using the required fields

#siteMapFolder(2,2,"/folder1/myFolder")

This would build a site map for everything 2 levels beneath /folder1/myFolder and go 2 levels deep.

Example 2: An example showing how to include one or more of the optional parameters

#set($reverseOrder = true)
$siteMapFolder(2,2,"/folder1/myFolder")

This would build a site map for everything 2 levels beneath /folder1/myFolder and go 2 levels deep in inverse order. 

Example 3: An example showing how to include one or more of the optional parameters

#set($showHome = true)
#siteMapFolder(2,2,"/folder1/myFolder")

This would build a site map for everything 2 levels beneath /folder1/myFolder and go 2 levels deep adding a link called: Home linked to the site's Home Page.