Topic: submenu snippet

snippet:

select('[slug="'.$current_page.'"]', null);
                // try again if we have a parent                
                if (trim($page['parent']) !== '') {
                    $parent_page = Pages::$pages->select('[slug="'.$page['parent'].'"]', null);
                    $pages = Pages::$pages->select('[parent="'.(string)$parent_page['slug'].'"]', 'all');
                }
            }
        }
        return $pages;
    }
    $sub_pages = snippet_submenu();
    if (isset($sub_pages)) {
?>
        

usage:

{snippet get="submenu"}

http://antiben.an.funpic.de/pictures/monstra_navpills.png