public function getBreadcrumbItems($maxDepth = 20, $stopAtPageType = false, $showHidden = false)
    {
        $page = $this;
        $pages = array();

        while ($page
            && $page->exists()
            && (!$maxDepth || count($pages) < $maxDepth)
            && (!$stopAtPageType || $page->ClassName != $stopAtPageType)
        ) {
            if ($showHidden || $page->ShowInMenus || ($page->ID == $this->ID)) {
                $pages[] = $page;
            }

            $page = $page->Parent();
        }

        return new ArrayList(array_reverse($pages));
    }
public function getBreadcrumbItems($maxDepth = 20, $stopAtPageType = false, $showHidden = false)
    {
        $page = $this;
        $pages = array();

        while ($page
            && $page->exists()
            && (!$maxDepth || count($pages) < $maxDepth)
            && (!$stopAtPageType || $page->ClassName != $stopAtPageType)
        ) {
            if ($showHidden || $page->ShowInMenus || ($page->ID == $this->ID)) {
                $pages[] = $page;
            }

            $page = $page->Parent();
        }

        return new ArrayList(array_reverse($pages));
    }
public function getBreadcrumbItems ( $ maxDepth = 20 , $ stopAtPageType = false , $ showHidden = false ) { $ page = $ this ; $ pages = array ( ) ; while ( $ page && $ page -> exists ( ) && ( ! $ maxDepth || count ( $ pages ) < $ maxDepth ) && ( ! $ stopAtPageType || $ page -> ClassName != $ stopAtPageType ) ) { if ( $ showHidden || $ page -> ShowInMenus || ( $ page -> ID == $ this -> ID ) ) { $ pages [ ] = $ page ; } $ page = $ page -> Parent ( ) ; } return new ArrayList ( array_reverse ( $ pages ) ) ; }
Returns a list of breadcrumbs for the current page.

@param int $maxDepth The maximum depth to traverse.
@param boolean|string $stopAtPageType ClassName of a page to stop the upwards traversal.
@param boolean $showHidden Include pages marked with the attribute ShowInMenus = 0

@return ArrayList
Returns a list of breadcrumbs for the current page .