Index: branches/2.8.x/wb/modules/show_menu2/uninstall.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/uninstall.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/uninstall.php	(nonexistent)
@@ -1,23 +0,0 @@
-<?php
-/**
- *
- * @category        modules
- * @package         show_menu2
- * @author          Independend-Software-Team
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link            http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-// Must include code to stop this file being access directly
-if(defined('WB_PATH') == false) { exit("Cannot access this file directly"); }
-
-?>
\ No newline at end of file

Property changes on: branches/2.8.x/wb/modules/show_menu2/uninstall.php
___________________________________________________________________
Deleted: svn:eol-style
## -1 +0,0 ##
-native
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Deleted: svn:mime-type
## -1 +0,0 ##
-text/plain
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/install.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/install.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/install.php	(nonexistent)
@@ -1,24 +0,0 @@
-<?php
-/**
- *
- * @category        modules
- * @package         show_menu2
- * @author          Independend-Software-Team
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link            http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-// Must include code to stop this file being access directly
-if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
-
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/install.php
___________________________________________________________________
Deleted: svn:eol-style
## -1 +0,0 ##
-native
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Deleted: svn:mime-type
## -1 +0,0 ##
-text/plain
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/legacy.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/legacy.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/legacy.php	(nonexistent)
@@ -1,193 +0,0 @@
-<?php
-/**
- *
- * @category        module
- * @package         show_menu2
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link			http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.7.0 | 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource		$HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-/*
-    This file provides backward compatibility between show_menu2 and the
-    old functions show_menu() and menu(). Note that it is highly recommended 
-    for you to update your templates to use show_menu2 directly.
- */    
-
-/* ----------------------------------------------------------------------------
-   show_menu
-   
- From: http://forum.websitebaker.org/index.php/topic,2251.msg13978.html#msg13978  
- 
- * By calling it multiple times, you can have one menu just
- * showing the root level, one for the sub-pages, and so on
- * The order of the arguments has been changed compared
- * to the page_menu() function, so read carefully the list
- * of arguments!
- * To just display the standard menu, use
- * <?php show_menu(); ?> within your template's html code.
- * You don't normally need anymore than the first four arguments.
- * Usual calls would be (inside php code!)
- * show_menu(1,0,-1,false); - displays the complete page tree
- * show_menu(1,1,1); - show only first sub level
- * show_menu(1,1,-1); -    show an expanding/collapsing menu tree starting at level 1
- * Have fun experimenting!
- *
- * Full list of arguments:
- * 1. $menu_number:   With activitated "multiple menu" feature
- *                  you can choose which menu will be displayed
- *                  default: 1
- * 2. $start_level: The depth level of the root of the displayed
- *               menu tree. Defaults to '0', which is the top level.
- *                  '1' will show all pages starting from the first sub level.
- * 3. $recurse:     Gives the maximum number of levels to be displayed. Default
- *                  is '-1' which means 'all'.
- * 4. $collapse:    Specifies, whether the menu tree shall be
- *               expandable/collapsible (if set to 'true')
- *               or complete (all pages being displayed) if set to 'false'
- * 5. $item_template: Gives the possibility to specify the html code that is
- *                  displayed before displaying sub-pages
- * 6. $item_footer: The html code to appear after sub-pages were displayed.
- * 7. $menu_header: The html code to appear before the entire menu code and each
- *               sub tree.
- * 8. $menu_footer: The html code to appear after the entire menu code and each
- *               sub tree.
- * 9. $default_class: The (CSS) class of every menu item except the currently viewed page
- * 10. $current_class: The class of the currently viewed page
- * 11. $parent:    (used internally) The page_id of the menu's root node, defaults is '0' (root level)
- */
-
-// Must include code to stop this file being access directly
-if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
- 
-class SM2_ShowMenuFormatter
-{
-    var $output;
-    var $itemTemplate;
-    var $itemFooter;
-    var $menuHeader;
-    var $menuFooter;
-    var $defaultClass;
-    var $currentClass;
-    
-    function output($aString) {
-        if ($this->flags & SM2::BUFFER) {
-            $this->output .= $aString;
-        }
-        else {
-            echo $aString;
-        }
-    }
-    function initialize() { $this->output = ''; }
-    function startList($aPage, $aUrl) { 
-        echo $this->menuHeader;
-    }
-    function startItem($aPage, $aUrl, $aCurrSib, $aSibCount) { 
-        // determine the class string to use
-        $thisClass = $this->defaultClass;
-        if ($aPage['page_id'] == PAGE_ID) {
-            $thisClass = $this->currentClass;
-        }
-        
-        // format and display this item
-        $item = str_replace( 
-                array(
-                    '[a]','[/a]','[menu_title]','[page_title]','[url]',
-                    '[target]','[class]'
-                    ),
-                array(
-                    "<a href='$aUrl' target='".$aPage['target']."'>", '</a>',
-                    $aPage['menu_title'], $aPage['page_title'], $aUrl, 
-                    $aPage['target'], $thisClass
-                    ),
-                $this->itemTemplate);
-        echo $item;
-    }
-    function finishItem() { 
-        echo $this->itemFooter;
-    }
-    function finishList() { 
-        echo $this->menuFooter;
-    }
-    function finalize() { }
-    function getOutput() {
-        return $this->output;
-    }
-}
-
-function show_menu(
-    $aMenu          = 1, 
-    $aStartLevel    = 0, 
-    $aRecurse       = -1, 
-    $aCollapse      = true,
-    $aItemTemplate  = '<li><span[class]>[a][menu_title][/a]</span>',
-    $aItemFooter    = '</li>',
-    $aMenuHeader    = '<ul>',
-    $aMenuFooter    = '</ul>',
-    $aDefaultClass  = ' class="menu_default"',
-    $aCurrentClass  = ' class="menu_current"',
-    $aParent        = 0
-    )
-{
-    static $formatter;
-    if (!isset($formatter)) {
-        $formatter = new SM2_ShowMenuFormatter;
-    }
-    
-    $formatter->itemTemplate  = $aItemTemplate;
-    $formatter->itemFooter    = $aItemFooter;  
-    $formatter->menuHeader    = $aMenuHeader;  
-    $formatter->menuFooter    = $aMenuFooter;  
-    $formatter->defaultClass  = $aDefaultClass;
-    $formatter->currentClass  = $aCurrentClass;
-    
-    $start = SM2::ROOT + $aStartLevel;
-    if ($aParent != 0) {
-        $start = $aParent;
-    }
-
-    $maxLevel = 0;
-    if ($aRecurse == 0) {
-        return;
-    }
-    if ($aRecurse < 0) {
-        $maxLevel = SM2::ALL;
-    }
-    else {
-        $maxLevel = SM2::START + $aRecurse - 1;
-    }
-    
-    $flags = $aCollapse ? SM2::TRIM : SM2::ALL;
-    
-    // special case for default case
-    if ($aStartLevel == 0 && $aRecurse == -1 && $aCollapse) {
-        $maxLevel = SM2::CURR + 1;
-    }
-
-    show_menu2($aMenu, $start, $maxLevel, $flags, $formatter);
-}
-
-function page_menu(
-    $aParent = 0, 
-    $menu_number = 1, 
-    $item_template = '<li[class]>[a][menu_title][/a]</li>', 
-    $menu_header = '<ul>', 
-    $menu_footer = '</ul>', 
-    $default_class = ' class="menu_default"', 
-    $current_class = ' class="menu_current"', 
-    $recurse = LEVEL    // page['level']
-    ) 
-{
-    show_menu($menu_number, 0, $recurse+2, true, $item_template, '', 
-        $menu_header, $menu_footer, $default_class, $current_class, $aParent);
-}
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/legacy.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/README.en.txt
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/README.en.txt	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/README.en.txt	(nonexistent)
@@ -1,607 +0,0 @@
-show_menu2, version 4.9
-=======================
-A code snippet for the Website Baker CMS software. It provides a complete
-replacement for the builtin menu functions. All menu data is retrieved using
-a single database query, all types of menu styles (lists, breadcrums, sitemaps)
-can be generated with extensive customisation of the resulting HTML.
-
-
-
-INSTALLATION
-============
-1. Download the latest version from http://code.jellycan.com/show_menu2/
-2. Log into your WebsiteBaker installation
-3. Go to Addons -> Modules
-4. If a previous version of show_menu2 is already installed, select it from
-   the "Uninstall Module" list and choose the "Uninstall" button.
-5. In the "Install Module" section, enter the path to the show_menu2 zip file
-   that you downloaded in step 1, and choose the "Install" button.
-
-
-
-USING SHOW_MENU2
-================
-You need to modify the PHP files of your template to call show_menu2 where you
-wish to have the menu displayed. Remember when you replace calls to the old
-menu functions to use the new parameters that show_menu2 requires.
-
-Often times the default menu generated by show_menu2 is all that you need.
-This menu shows the current page and children of the current page. It is
-generated by just calling show_menu2 with no parameters. For example:
-
-    show_menu2();
-
-Note that the call to show_menu2 is PHP, so you usually need to wrap it in the
-PHP code brackets so that it will execute. Like this:
-
-    <?php show_menu2(); ?>
-
-This default menu generates a complete list based menu with many classes that
-allow easy CSS styling. For example, the current menu item will have the
-"menu-current" class added to the <li> tag. Additionally, every menu item with
-a sub-menu will have the "menu-expand" class added to the <li> tag. This allows
-you to create CSS rules to style those menu items differently. For example:
-
-    li.menu-expand  { font-weight: bold; }
-    li.menu-current { background: red; }
-
-See the "Output" section for details of exactly what classes are added to each
-element. More elaborate and different menu structures are able to be created by
-supplying different parameters to the show_menu2 function call. For example,
-to show only menu items from the top level of the menu you use:
-
-    show_menu2(0, SM2_ROOT, SM2_START);
-
-Alternatively, to show up to two levels of the child menus of the current page:
-
-    show_menu2(0, SM2_CURR+1, SM2_CURR+2);
-
-There are many more possible menus that can be generated by show_menu2. See the
-demonstration website at http://code.jellycan.com/sm2test/ for more examples.
-
-
-
-COMMON QUESTIONS
-================
-
-Q:  I'm not a programmer. Do you have simpler documentation?
-A:  Nup. This is it. Go hard. Gambarre.
-
-
-Q:  How do I create a drop-down menu?
-A:  This is unrelated to show_menu2. You need to change the template CSS code
-    to display the menu as a drop-down. Try the "allcss2" template from the WB
-    addon repository. http://addons.websitebaker.org/
-
-
-Q:  Why does the menu disappear after I do a search on my multilingual WB site?
-A:  You're missing some required lines in your template.
-
-    1.  Log into WB administration, and go to Settings -> Show advanced settings
-        -> Search Settings -> Header Code and add the following input field
-        after the <form> open tag:
-
-        <input type="hidden" name="referrer" value="[REFERRER_ID]" />
-
-
-    2.  In the index.php of your template, add the following input field
-        immediately following the search <form> open tag.
-
-        <input type="hidden" name="referrer" value="<?php echo defined('REFERRER_ID')?REFERRER_ID:PAGE_ID;?>" />
-
-
-Q:  Multilingual? That sounds cool. How do I do that?
-A:  http://www.websitebaker2.org/en/help/designer-guide/multilingual-websites.php
-
-
-Q:  SM2 is generating a warning every time the page is accessed:
-    "show_menu2 error: $aOptions is invalid. No flags from group 1 supplied!"
-A:  You are passing the wrong values to the function. Have a closer look at the
-    parameters that you are passing. See the PARAMETERS section below for the
-    correct flag values to pass for the $aOptions parameter.
-
-
-Q:  How do I use a different class/picture/color/widget for each entry in a menu?
-A:  Use the [page_id] format string in the $aItemOpen string. Create a unique
-    class or id for each menu item, then reference that item in your CSS or Javascript
-    to do whatever you want.
-
-    To add a unique class for each menu item (or similar):
-
-        "<li><a href="[url]" target="[target]" class="[class] p[page_id]">[menu_title]</a>"
-
-        ... creating menu items like ...
-
-        <li><a href="/pages/foo/bar.php" target="_top" class="menu-top p45">Top Menu</a>
-
-        Reference this in your CSS like:
-
-        a.p45 { color: red; }
-
-    To add a unique ID for each menu item (or similar):
-
-        "<li><a id="p[page_id]" href="[url]" target="[target]" class="[class]">[menu_title]</a>"
-
-        ... creating menu items like ...
-
-        <li><a id="p45" href="/pages/foo/bar.php" target="_top" class="menu-top">Top Menu</a>
-
-        Reference this in your CSS like:
-
-        a#p45 { color: red; }
-
-        Note that the ID can only be used if that menu is generated and displayed one time
-        only on the page (because HTML ID's must be unique within a page).
-
-
-
-FUNCTION
-========
-
-The complete call signature and default parameter value for show_menu2 is:
-
-    show_menu2(
-        $aMenu          = 0,
-        $aStart         = SM2_ROOT,
-        $aMaxLevel      = SM2_CURR+1,
-        $aOptions       = SM2_TRIM,
-        $aItemOpen      = '[li][a][menu_title]</a>',
-        $aItemClose     = '</li>',
-        $aMenuOpen      = '[ul]',
-        $aMenuClose     = '</ul>',
-        $aTopItemOpen   = false,
-        $aTopMenuOpen   = false
-        )
-
-See the "Parameters" section for detailed descriptions of each parameter.
-Ensure that you use each parameter correctly. Use the following rules:
-
-    $aMenu will be 0 for most people.
-
-    $aStart must be either a page ID or a value starting with "SM2_".
-
-    $aMaxLevel must be only values that start with "SM2_".
-
-    $aOptions must be only values that start with "SM2_" (unless you are
-    in a very small minority of users).
-
-    All other parameters are the HTML tag templates that will be
-    output for menus and menu items.
-
-Note that every parameter from $aItemOpen can be supplied as false to get
-the default value.
-
-
-
-HTML OUTPUT
-===========
-The menu is output differently depending on what parameters have been
-supplied to the function, however in general the following classes are used
-for each menu. Note that items will have multiple classes when relevant.
-
-    CLASS           ATTACHED TO
-    ------------    -------------------------------------------------------
-    menu-top        First menu tag only
-    menu-parent     Every parent menu item of the current page.
-    menu-current    Only the menu item for the current page.
-    menu-sibling    Every sibling of the current page.
-    menu-child      Every sub-menu of the current page.
-    menu-expand     Every menu item with children.
-    menu-first      First item in any menu or sub-menu.
-    menu-last       Last item in any menu or sub-menu.
-
-    The following classes are added only if SM2_NUMCLASS flag has been used.
-
-    menu-N          Every menu item. The N is replaced with the ABSOLUTE
-                    menu depth of the item starting with 0. The root level
-                    menu is always menu-0, the next level is menu-1, etc.
-    menu-child-N    Every sub-menu of the current page, the N is replaced
-                    with the relative depth of the submenu starting at 0.
-
-
-<ul class="menu-top menu-0">
-  <li class="menu-0 menu-first">  ... </li>
-  <li class="menu-0 menu-expand menu-parent">  ...
-  <ul class="menu-1">
-    <li class="menu-1 menu-expand menu-first">  ...
-    <ul class="menu-2">
-      <li class="menu-2 menu-first">  ...
-      <li class="menu-2 menu-last">  ...
-    </ul>
-    </li>
-    <li class="menu-1 menu-expand menu-parent">  ...
-    <ul class="menu-2">
-      <li class="menu-2 menu-expand menu-current menu-first">  ...      ** CURRENT PAGE **
-      <ul class="menu-3">
-        <li class="menu-3 menu-child menu-child-0 menu-first">  ...
-        <ul class="menu-4">
-          <li class="menu-4 menu-child menu-child-1 menu-first">  ... </li>
-          <li class="menu-4 menu-child menu-child-1 menu-last">  ... </li>
-        </ul>
-        </li>
-        <li class="menu-3 menu-child menu-child-0 menu-last">  ... </li>
-      </ul>
-      </li>
-      <li class="menu-2 menu-sibling menu-last">  ... </li>
-    </ul>
-    </li>
-    <li class="menu-1">  ... </li>
-    <li class="menu-1 menu-expand menu-last">  ...
-    <ul class="menu-2">
-      <li class="menu-2 menu-first menu-last">  ... </li>
-    </ul>
-    </li>
-  </ul>
-  </li>
-  <li class="menu-0 menu-last">  ... </li>
-</ul>
-
-
-
-PARAMETERS
-==========
-$aMenu
-    Menu number to use. This is useful when you are using multiple menus.
-    Supplying a menu number of 0 will use the default menu for the current
-    page. Supplying SM2_ALLMENU will return all menus in the system.
-
-$aStart
-    Specify where the menu generation should start from. This is most
-    times the parent item of the menu to display. It must be one of the
-    following values:
-        SM2_ROOT+N  Start N levels down from the root. e.g.
-                      SM2_ROOT      Starting at the root menu
-                      SM2_ROOT+1    Start 1 level below the root
-                      SM2_ROOT+2    Start 2 levels below the root
-        SM2_CURR+N  Start N levels down from the current page level. e.g.
-                      SM2_CURR      Starts at the current page level. All
-                                    sibling menus to the current page.
-                      SM2_CURR+1    Starts 1 level down from the current
-                                    page with the children menus.
-        page_id     Display using the specific page as the parent. All
-                    child menus of that page will be displayed. The
-                    page_id can be found by editing the page in WB admin
-                    interface. The page_id is included in the URL like:
-                        http://SITE/admin/pages/modify.php?page_id=35
-
-$aMaxLevel
-    Maximum menu level to display. Menus are displayed from the start
-    level down to this level.
-        SM2_ALL     No limit, all levels are displayed
-        SM2_CURR+N  Always show to the current page + N levels.
-                      SM2_CURR      Current (no children)
-                      SM2_CURR+3    All parents + current + 3 children
-        SM2_START+N Always show from the starting level + N levels. The
-                    levels of menu will always be displayed regardless of
-                    what level the current page is.
-                      SM2_START     Single level of menus from starting level
-                      SM2_START+1   Starting level and 1 level down
-        SM2_MAX+N   Show at most N levels from the starting level. Levels
-                    won't be shown if they are below the current level.
-                      SM2_MAX       Starting level only (same as SM2_START)
-                      SM2_MAX+1     Maximum of starting level and 1 level.
-
-$aOptions
-    Specify flags for different generation options for the menu. The flags
-    may be combined together using bitwise OR (|). For example, to specify
-    both TRIM and PRETTY you should use, (SM2_TRIM | SM2_PRETTY).
-
-    GROUP 1
-    -------
-    Exactly one flag from this group must always be supplied. These flags
-    affect how the siblings in the tree are removed from the output.
-
-    SM2_ALL         Show all branches of the menu tree
-                        A-1 -> B-1
-                            -> B-2 -> C-1
-                                   -> C-2 (CURRENT)
-                                          -> D-1
-                                          -> D-2
-                                   -> C-3
-                        A-2 -> B-3
-                            -> B-4
-    SM2_TRIM        Show all sibling menus of pages on the current path.
-                    All sub-menus of elements that are not on the path
-                    are removed.
-                        A-1 -> B-1
-                            -> B-2 -> C-1
-                                   -> C-2 (CURRENT)
-                                          -> D-1
-                                          -> D-2
-                                   -> C-3
-                        A-2
-    SM2_CRUMB       Show only the breadcrumb trail, i.e. the current
-                    menu and all of it's ancestor menus.
-                        A-1 -> B-2 -> C-2 (CURRENT)
-    SM2_SIBLING     The same as SM2_TRIM however only sibling menus of
-                    the current page are displayed. All other menus are
-                    trimmed to show only the path.
-                        A-1 -> B-2 -> C-1
-                                   -> C-2 (CURRENT)
-                                          -> D-1
-                                          -> D-2
-                                   -> C-3
-
-    GROUP 2
-    -------
-    All of these flags are optional. Any number of them may be combined.
-
-    SM2_NUMCLASS    Add the numbered menu classes to the menu. If this
-                    flag is supplied, the "menu-N" and "menu-child-N"
-                    classes will be added.
-
-    SM2_ALLINFO     Load all fields from the page table of the database.
-                    This will result in quite a lot of memory being used
-                    and is not recommended, however it will make keywords,
-                    descriptions, and other fields available. This data
-                    is not loaded by default.
-                    NOTE: This flag must be used on the *FIRST* call to
-                    show_menu2 *for this menu ID*, or in combination with
-                    SM2_NOCACHE otherwise it will have no effect.
-
-    SM2_NOCACHE     Do not reuse or store the data read from the database
-                    between calls to show_menu2.
-
-    SM2_PRETTY      Pretty print the menu HTML with spacing and newlines
-                    for debugging purposes.
-
-    SM2_BUFFER      Do not output the menu HTML but instead buffer it
-                    internally and return it as a string from show_menu2.
-
-    SM2_CURRTREE    Exclude all other top level menus from being considered.
-                    Only items in the current menu tree will be output.
-                    This can be combined with any of the Group 1 flags as
-                    necessary.
-
-    SM2_ESCAPE      Call htmlspecialchars on the menu strings. This may be
-                    required with older installations of WB. By escaping the
-                    raw database strings, it permits menus to have HTML
-                    formatting in them that would cause otherwise cause
-                    pages to fail validation.
-
-    SM2_SHOWHIDDEN  Hidden pages are usually hidden all of the time, including
-                    when they are active (i.e. current page or a parent page).
-                    Use private pages for time when you want pages to be
-                    hidden except when active. However for compatibility with
-                    release 4.8, supply this flag to enable hidden pages to
-                    become visible when they are active.
-
-    SM2_XHTML_STRICT	From all links, created by [a] or [ac], the 'target' -
-					attribute will be removed to preserve the XHTML-Compatibility
-
-	SM2_NO_TITLE	Supress the value of the 'title'-attributes on links which
-					are created by [a] or [ac] formatted links.
-
-    This parameter also has an extended mode where an associative array of
-    options is supplied. See the EXTENDED OPTIONS section for details.
-    Most users will NOT need to use this.
-
-$aItemOpen
-    Format string to use for creating each individual menu item entry.
-    A different format string may be used for the very first entry by
-    supplying a different format string for $aTopItemOpen. When set to
-    false, it uses the default of '[li][a][menu_title]</a>' to maintain
-    compatibility with show_menu(). Note however that CSS formatting is
-    often easier if the classes are added to the <a> tag. Use the format
-    string of '<li>[ac][menu_title]</a>' for this style of tag.
-
-    This parameter may also be specified as an instance of a formatting
-    class for the menu. See the section "Formatter" below for details of
-    the API this class must expose. When a formatter is supplied, all
-    arguments after $aItemOpen are ignored.
-
-$aItemClose
-    String used to close each item. Note that this is not a format
-    string and no keywords will be replaced. When set to false, it uses
-    the default of '</li>'.
-
-$aMenuOpen
-    Format string to use for opening a list of menu item entries. A
-    different format string may be used for the very first menu by
-    supplying a different format string for $aTopMenuOpen. When set to
-    false, it uses the default of '[ul]'.
-
-$aMenuClose
-    String used to close each menu. Note that this is not a format
-    string and no keywords will be replaced. When set to false, it uses
-    the default of '</ul>'.
-
-$aTopItemOpen
-    Format string for the first item. When set to false, it uses the same
-    format as $aItemOpen.
-
-$aTopMenuOpen
-    Format string for the first menu. When set to false, it uses the same
-    format as $aMenuOpen.
-
-
-
-EXTENDED OPTIONS
-================
-The $aOptions parameter is a dual mode parameter. For most users, only the
-SM2_* flags will be sufficient. However, to access the extra options, it
-must be supplied as an associative array. Note that the SM2_* flags are
-still required and must be supplied as 'flags'.
-
-    'flags'     **REQUIRED** These are the flags described in PARAMETERS
-                above for the $aOptions parameter.
-
-    'notrim'    Specify a number of levels relative to the menu level of
-                $aStart that will always be displayed. This will cause the
-                SM2_TRIM flag to be ignored for these levels.
-
-To supply one of these options in addition to the flags, the option array
-should be created and passed as the $aOptions parameter:
-
-    $options = array('flags' => (SM2_TRIM|...), 'notrim' => 1);
-    show_menu2(0, SM2_ROOT, SM2_CURR+1, $options);
-
-
-
-FORMAT STRINGS
-==============
-The following tags may be included in the format strings for $aItemOpen and
-$aMenuOpen and will be replaced with the appropriate text.
-
-[a]             <a> tag (no class):         '<a href="[url]" target="[target]">'
-[ac]            <a> tag including class:    '<a href="[url]" target="[target]" class="[class]">'
-[li]            <li> tag including class:   '<li class="[class]">'
-[ul]            <ul> tag including class:   '<ul class="[class]">'
-[class]         List of classes for that page
-[menu_title]    Menu title text (HTML entity escaped unless SM2_NOESCAPE flag is used)
-[menu_icon_0]	URL poining to an image for display normal - status (from WB2.8.4)
-[menu_icon_1]	URL poining to an image for display active/hover - status (from WB2.8.4)
-[page_title]    Page title text (HTML entity escaped unless SM2_NOESCAPE flag is used)
-[page_icon]		URL poining to an image relating to the current page (from WB2.8.4)
-[tooltip]       Tooltip caption, normaly shown in title-attribute of links (ab WB2.8.4)
-[url]           Page URL for the <a> tag
-[target]        Page target for the <a> tag
-[page_id]       Page ID of the current menu item
-[parent]        Page ID of the parent menu item
-[level]         Page level, the same number as is used for the "menu-N" CSS tag.
-[sib]           Current menu sibling number
-[sibCount]      Total number of siblings in this menu
-[if]            Conditional test (see section CONDITIONAL FORMATTING)
-
-The following tags are only available when the SM2_ALLINFO flag is used.
-
-[description]   Page description
-[keywords]      Page keywords
-
-
-
-CONDITIONAL FORMATTING
-======================
-The conditional formatting directive takes one of the following forms:
-
-    [if(A){B}]
-    [if(A){B}else{C}]
-
-    A   Conditional test. See below for more details.
-
-    B   Expression emitted when the if-test is true. This may be any string
-        that does NOT include the '}' character. It may include any of the
-        format strings described in the section FORMAT STRINGS with the
-        exception of the conditional test (because '}' is not permitted).
-
-    C   Expression emitted when the if-test is false. This may be any string
-        that does NOT include the '}' character. It may include any of the
-        format strings described in the section FORMAT STRINGS with the
-        exception of the conditional test (because '}' is not permitted).
-
-The conditional test is a combination of one or more boolean tests.
-If more than one test is supplied, it must be combined with other tests
-using either || (boolean OR) or && (boolean AND).
-
-A single test is made up of the left operand, operator and right operand.
-e.g. X == Y where X is the left operand, == is the operator and Y is the
-right operand.
-
-    Left operand. It must be one of the following keywords:
-        class       Test for existence of one of the classes. Only the
-                    "==" and "!=" operators are permitted. In this case
-                    these operators have the meaning of "includes"
-                    instead of "equals".
-        level       Test against the page level.
-        sib         Test against the current page sibling number.
-        sibCount    Test against the number of siblings in the menu.
-        id          Test against the page id.
-		target		Test against the target attribute
-
-    Operator. It must be one of the following:
-        <           Less Than
-        <=          Less Than Equals
-        ==          Equals
-        !=          Not Equal
-        >=          Greater Than Equals
-        >           Greater Than
-
-    Right operand. The type of this operand depends on the keyword used
-    for the left operand:
-        class       One of the "menu-*" class names as listed in the
-                    section "OUTPUT".
-        level       Test the page level against the following values:
-                      <number>  absolute page level
-                      root      the root page level
-                      granny    the grand-parent page level
-                      parent    the parent page level
-                      current   the current page level
-                      child     the child page level
-        id          Test the page id against the following values:
-                      <number>  absolute page id
-                      parent    the parent page id
-                      current   the current page id
-        sib         A positive integer, or "sibCount" to test against
-                    the count of siblings in this menu.
-        sibCount    A positive integer.
-		target		A string, containing a possible target
-
-For example, valid tests are expression "exp" is emitted only when the menu item:
-
-    [if(class==menu-expand){exp}]   has a sub-menu
-    [if(class==menu-first){exp}]    is first item in a menu
-    [if(class!=menu-first){exp}]    is NOT first item in a menu
-    [if(class==menu-last){exp}]     is last item in a menu
-    [if(level==0){exp}]             is at the root
-    [if(level>0){exp}]              is not at the root
-    [if(sib==2){exp}]               is the second item in a menu
-    [if(sibCount>1){exp}]           is in a menu with more than 1 entry
-    [if(sibCount!=2){exp}]          is in a menu which doesn't have exactly
-    [if(level>parent){exp}]         is in a sibling menu or child of a sibling
-    [if(id==parent){exp}]           is the parent of the current page
-	[if(target==_self){exp}]		if value of target-attribute is '_self'
-
-If an else-clause was added, then the expression for the else would be
-emitted in all other cases. For example the expression "foo" is emitted
-whenever the if-test is false, so therefore:
-
-    [if(sib==2){exp}else{foo}]          is NOT the second item in a menu
-    [if(sibCount>2){exp}else{foo}]      is NOT in a menu with more than 2 entries
-
-For multiple tests, the expression "exp" is emitted only when the menu item:
-
-    [if(sib == 1 || sib > 3){exp}]
-        [is the first item] OR [is the 4th or larger item] in the menu
-
-    [if(id == current && class == menu-expand){exp}
-        [is the current item] AND [it has children]
-
-Note that all tests are evaluated in the order listed because:
- * there is no short-circuit evaluation (all individual tests are always evaluated)
- * there is no grouping of tests (i.e. no support for parenthesis)
- * both || and && are considered the same level
-
-
-
-FORMATTER
-=========
-Note: This is an advanced and rarely needed feature!
-
-If you are capable of extensive PHP programming, it is possible to replace the
-predefined menu formatter that show_menu2 is uses with a custom module. See the
-include.php file of show_menu2 for an example of how the menu formatter must be
-written. The API it must use is:
-
-class SM2_Formatter
-{
-    // called once before any menu is processed to allow object initialization
-    function initialize() { }
-
-    // called to open the menu list
-    function startList($aPage, $aUrl) { }
-
-    // called to open the menu item
-    function startItem($aPage, $aUrl, $aCurrSib, $aSibCount) { }
-
-    // called to close the menu item
-    function finishItem() { }
-
-    // called to close the menu list
-    function finishList() { }
-
-    // called once after all menu has been processed to allow object finalization
-    function finalize() { }
-
-    // called once after finalize() if the SM2_NOOUTPUT flag is used
-    function getOutput() { }
-};

Property changes on: branches/2.8.x/wb/modules/show_menu2/README.en.txt
___________________________________________________________________
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/upgrade.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/upgrade.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/upgrade.php	(nonexistent)
@@ -1,23 +0,0 @@
-<?php
-/**
- *
- * @category        modules
- * @package         show_menu2
- * @author          Independend-Software-Team
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link            http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-// Must include code to stop this file being access directly
-if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/upgrade.php
___________________________________________________________________
Deleted: svn:eol-style
## -1 +0,0 ##
-native
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Deleted: svn:mime-type
## -1 +0,0 ##
-text/plain
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/README.de.txt
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/README.de.txt	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/README.de.txt	(nonexistent)
@@ -1,668 +0,0 @@
-﻿show_menu2, version 4.9
-=======================
-Ist ein Code-Snippet für das CMS Website Baker. Es stellt einen kompletten
-Ersatz für die eingebaute Menüfuntionalität zur Verfügung. Alle, für die
-Erzeugung des Menüs erforderlichen Daten, werden durch eine einzige
-Datenbankabfrage erzeugt. Durch umfangreiche Anpassungsmöglichkeiten des
-erzeugten HTML-Code können alle möglichen Menüarten (Listen, Breadcrumbs,
-Sitemaps, usw.) erzeugt werden.
-
----
-Deutsche Übersetzung von BerndJM. Dies ist eine weitgehend direkte Übersetzung
-des englischen Originals. Bei Übersetzungs- oder Interpretationsfehlern, bitte
-eine Email an bjm@wwnw.de.
----
-
-
-
-INSTALLATION
-============
-1. Die aktuelle Version von http://code.jellycan.com/show_menu2/ herunterladen.
-2. In das Admin-Backend der Website Baker Installation einlogen.
-3. Erweiterungen -> Module aufrufen.
-4. Wenn bereits eine frühere Version von show_menu2 installiert ist, diese über
-   "Modul deinstallieren" auswählen und deinstallieren.
-5. Im Abschnitt "Modul installieren" das im Schritt 1 heruntergeladene zip-File
-   auswählen und installieren.
-
-
-
-BENUTZUNG VON SHOW_MENU2
-========================
-Um show_menu2 zu benutzen muss das verwendete Template an den Stellen
-modifiziert werden, an denen das Menü erscheinen soll. Bitte beachten: Wenn alte
-Menüaufrufe ersetzt werden, müssen unbedingt auch die entsprechenden neuen
-Parameter verwendet werden die show_menu2 benötigt.
-
-In den meisten Fällen genügt bereits der Standardaufruf ohne weitere Parameter
-von show_menu2. In diesem Fall werden die Vorgabewerte verwendet, dies erzeugt
-ein Menü das die aktuelle Seite und die Unterseiten der aktuellen Seite anzeigt:
-
-    show_menu2();
-
-Bitte beachten: der Aufruf von show_menu2 ist PHP und muss normalerweise in PHP-
-Codezeichen eingeschlossen werden (ausser der Aufruf erfolgt bereits innerhalb
-von PHP Code):
-
-    <?php show_menu2(); ?>
-
-Dieses Vorgabe Menü erzeugt bereits ein komplettes Menü auf Listenbasis mit
-etlichen Klassen, die eine leichte Formatierung mittels CSS ermöglichen. Es wird
-z.B. die Klasse "menu-current" zu dem <li> tag des aktuellen Menüpunktes
-hinzugefügt. Zusätzlich erhält jeder Menüpunkt der Unterpunkte enthält die
-Klasse "menu-expand". Das erlaubt es sehr differenzierte CSS Regeln für die
-einzelnen Menüpunkte aufzustellen.
-Zum Beispiel:
-
-    li.menu-expand  { font-weight: bold; }
-    li.menu-current { background: red; }
-
-Im Abschnitt "HTML-Ausgabe" findet sich eine detaillierte Beschreibung welche
-Klassen welchem Element zugeordnet werden. Durch die Verwendung von
-verschiedenen Parametern bei dem show_menu2 Funktionsaufruf lassen sich auch
-recht umfangreiche und unterschiedliche Menüstrukturen erzeugen. Um
-beispielsweise nur Menüpunkte aus der obersten Ebene der Menüstruktur
-darzustellen, könnte man folgenden Aufruf verwenden:
-
-    show_menu2(0, SM2_ROOT, SM2_START);
-
-Oder um beispielsweise bis zu zwei Unterebenen der aktuellen Seite anzuzeigen:
-
-    show_menu2(0, SM2_CURR+1, SM2_CURR+2);
-
-Es gibt jede Menge Möglichkeiten, um die unterschiedlichsten Menüstrukturen zu
-erzeugen. Zahlreiche Beispiele dazu findet man auf der Demo-Website: http://
-code.jellycan.com/sm2test/
-
-
-
-HÄUFIGE FRAGEN
-==============
-
-Q:  Ich bin kein Programmierer. Gibt es keine einfachere Dokumentation?
-A:  Nein, denn dies hier ist bereits die einfache Dokumentation.
-
-
-Q:  Wie kann ich ein sogenanntes Drop-Down Menü erstellen?
-A:  Dies hat nichts mit show_menu2 zu tun. Um ein Drop-Down Menü zu erzeugen muß
-    lediglich der CSS-Code des jeweiligen Templates angepaßt werden. Die nötigen
-    Anpassungen findet man z.B. im "allcss2" Template aus dem WB Addon
-    Repository -> http://addons.websitebaker.org/
-
-
-Q:  Warum verschwindet das Menü nachdem ich in einer mehrsprachigen WB-Site die
-    Suchfunktion benutzt habe?
-A:  Im verwendeten Template fehlen die notwendigen Zeilen:
-
-    1.  Im WB Admin Backend: Optionen -> Erweiterte Optionen anzeigen ->
-        Suchoptionen -> Kopfzeile - hier direkt nach dem öffnenden <form> tag
-        folgende Zeile einfügen:
-
-        <input type="hidden" name="referrer" value="[REFERRER_ID]" />
-
-    2.  In der index.php des verwendeten Templates folgende Zeile unmittelbar
-        nach dem öffnenden <form> tag der Suche einfügen:
-
-        <input type="hidden" name="referrer" value="<?php echo defined('REFERRER_ID')?REFERRER_ID:PAGE_ID;?>" />
-
-
-Q:  Mehrsprachig? Das klingt toll. Wie macht man das?
-A:  http://www.websitebaker2.org/de/hilfe/designerhandbuch/mehrsprachige-webseiten.php
-
-
-Q:  Jedesmal wenn eine Seite aufgerufen wird, erzeugt SM2 folgende Warnmeldung:
-    "show_menu2 error: $aOptions is invalid. No flags from group 1 supplied!"
-A:  Der Funktion wurden die falschen Werte oder eine falsche Anzahl an
-    Werten übergeben.
-    Siehe den Abschnitt PARAMETER für die korrekten Flag Werte die dem
-    $aOptions Parameter zu übergeben sind.
-
-
-Q:  How do I use a different class/picture/color/widget for each entry in a menu?
-A:  Use the [page_id] format string in the $aItemOpen string. Create a unique
-    class or id for each menu item, then reference that item in your CSS or Javascript
-    to do whatever you want.
-
-    To add a unique class for each menu item (or similar):
-
-        "<li><a href="[url]" target="[target]" class="[class] p[page_id]">[menu_title]</a>"
-
-        ... creating menu items like ...
-
-        <li><a href="/pages/foo/bar.php" target="_top" class="menu-top p45">Top Menu</a>
-
-        Reference this in your CSS like:
-
-        a.p45 { color: red; }
-
-    To add a unique ID for each menu item (or similar):
-
-        "<li><a id="p[page_id]" href="[url]" target="[target]" class="[class]">[menu_title]</a>"
-
-        ... creating menu items like ...
-
-        <li><a id="p45" href="/pages/foo/bar.php" target="_top" class="menu-top">Top Menu</a>
-
-        Reference this in your CSS like:
-
-        a#p45 { color: red; }
-
-        Note that the ID can only be used if that menu is generated and displayed one time
-        only on the page (because HTML ID's must be unique within a page).
-
-
-FUNKTION
-========
-
-Der komplette Aufruf und die Vorgabe Parameterwerte für show_menu2 sind wie folgt:
-
-    show_menu2(
-        $aMenu          = 0,
-        $aStart         = SM2_ROOT,
-        $aMaxLevel      = SM2_CURR+1,
-        $aOptions       = SM2_TRIM,
-        $aItemOpen      = '[li][a][menu_title]</a>',
-        $aItemClose     = '</li>',
-        $aMenuOpen      = '[ul]',
-        $aMenuClose     = '</ul>',
-        $aTopItemOpen   = false,
-        $aTopMenuOpen   = false
-        )
-
-Im Abschnitt "Parameter" findet sich eine detaillierte Beschreibung jedes
-einzelnen Parameters.
-Jeder Parameter muß absolut korrekt verwendet werden. Folgende Regeln können
-dabei helfen:
-
-    $aMenu = 0 ist in den meisten Anwendungsfällen der beste Wert.
-
-    $aStart muß entweder eine page ID oder ein Wert der mit "SM2_" beginnt sein.
-
-    $aMaxLevel kann nur Werte erhalten, die mit "SM2_" beginnen.
-
-    $aOptions bis auf einige wenige Spezialfälle sind hier nur Werte die mit
-    "SM2_" beginnen zulässig.
-
-    Alle weiteren Parameter enthalten die (HTML)Tags die die Ausgabe des Menüs
-    steuern.
-
-    Ab $aItemOpen kann jedem Parameter der Wert false übergeben werden um den
-    jeweiligen Vorgabewert zu erhalten.
-
-    Dies kann beispielsweise verwendet werden um eine nummerierte Liste zu
-    erzeugen, während für die einzelnen Menüpunkte trotzdem die Vorgabewerte
-    Verwendung finden:
-
-        show_menu2(0, SM2_ROOT, SM2_ALL, SM2_ALL, false, false, '<ol>', '</ol>');
-
-Bitte beachten: bis einschliesslich $aOptions müssen alle Parameter explizit übergeben werden!
-
-
-HTML-AUSGABE
-============
-Die HTML-Ausgabe hängt wesentlich davon ab, welche Parameter an die Funktion übergeben werden.
-Unabhängig davon werden nachfolgende Klassen grundsätzlich für jedes Menü verwendet, wobei
-einzelne Menüpunkte, wenn es erforderlich ist, auch mehrere Klassen erhalten können.
-
-    KLASSE          ZUORDNUNG
-    ------------    -------------------------------------------------------
-    menu-top        Nur der erste Menüpunkt.
-    menu-parent     Jeder Hauptmenüpunkt.
-    menu-current    Nur der Menüpunkt der aktuellen Seite.
-    menu-sibling    Alle "Geschwister" der aktuellen Seite.
-    menu-child      Jedes Untermenü der aktuellen Seite.
-    menu-expand     Jedes Menü das Untermenüs hat.
-    menu-first      Der erste Punkt eines jeden Menüs oder Untermenüs.
-    menu-last       Der letzte Punkt eines jeden Menüs oder Untermenüs.
-
-    Folgende Klassen werden nur hinzugefügt, wenn das SM2_NUMCLASS Flag gesetzt
-    ist:
-
-    menu-N          Jeder Menüpunkt, wobei das N für die ABSOLUTE Menütiefe,
-                    beginnend bei 0, des jeweiligen Menüpunktes steht.
-                    Die oberste Ebene ist also immer menu-0, die nächste
-                    Ebene menu-1 usw.
-    menu-child-N    Jedes Untermenü der aktuellen Seiten, wobei das N für die
-                    RELATIVE Tiefe des Untermenüs, beginnend bei 0, steht.
-
-Beispiel einer HTML-Ausgabe:
-
-<ul class="menu-top menu-0">
-  <li class="menu-0 menu-first">  ... </li>
-  <li class="menu-0 menu-expand menu-parent">  ...
-  <ul class="menu-1">
-    <li class="menu-1 menu-expand menu-first">  ...
-    <ul class="menu-2">
-      <li class="menu-2 menu-first">  ...
-      <li class="menu-2 menu-last">  ...
-    </ul>
-    </li>
-    <li class="menu-1 menu-expand menu-parent">  ...
-    <ul class="menu-2">
-      <li class="menu-2 menu-expand menu-current menu-first">  ...      ** CURRENT PAGE **
-      <ul class="menu-3">
-        <li class="menu-3 menu-child menu-child-0 menu-first">  ...
-        <ul class="menu-4">
-          <li class="menu-4 menu-child menu-child-1 menu-first">  ... </li>
-          <li class="menu-4 menu-child menu-child-1 menu-last">  ... </li>
-        </ul>
-        </li>
-        <li class="menu-3 menu-child menu-child-0 menu-last">  ... </li>
-      </ul>
-      </li>
-      <li class="menu-2 menu-sibling menu-last">  ... </li>
-    </ul>
-    </li>
-    <li class="menu-1">  ... </li>
-    <li class="menu-1 menu-expand menu-last">  ...
-    <ul class="menu-2">
-      <li class="menu-2 menu-first menu-last">  ... </li>
-    </ul>
-    </li>
-  </ul>
-  </li>
-  <li class="menu-0 menu-last">  ... </li>
-</ul>
-
-
-PARAMETER
-=========
-$aMenu
-    Nummer des Menüs. Diese ist nützlich um mehrere Menüs auf einer Seite zu
-    verwenden.
-    Menü Nummer 0 ist das Vorgabemenü der aktuellen Seite, SM2_ALLMENU gibt alle
-    im System verwendeten Menüs zurück.
-
-$aStart
-    Gibt an, ab welcher Ebene die Erzeugung des Menüs beginnen soll. In den
-    meisten Fällen wird dies die oberste Ebene des anzuzeigenden Menüs sein. Es
-    kann einer der folgenden Werte verwendet werden:
-
-        SM2_ROOT+N  Beginnt N Ebenen unterhalb der obersten Ebene, z.B.:
-                    SM2_ROOT      Beginnt auf der obersten Ebene
-                    SM2_ROOT+1    Beginnt eine Ebene unterhalb der obersten Ebene
-                    SM2_ROOT+2    Beginnt zwei Ebenen unterhalb der obersten Ebene
-
-        SM2_CURR+N  Beginnt N Ebenen unterhalb der aktuellen Ebene, z.B.:
-                    SM2_CURR      Beginnt auf der aktuellen Ebene. Alle Geschwister
-                                  der aktuellen Ebene
-                    SM2_CURR+1    Beginnt eine Ebene unterhalb der aktuellen Ebene
-                                  mit allen Unterebenen
-
-        page_id     Verwendet die Seite mit der angegebenen page id als Elternelement.
-                    Alle Untermenüs dieser Seite werden angezeigt.
-                    (Die page id kann ermittelt werden, wenn man die Seite im
-                    Admin-Backend editiert, sie steht dann in der Adresszeile des
-                    Browsers: http://SITE/admin/pages/modify.php?page_id=35
-
-$aMaxLevel
-    Die maximale Anzahl der Ebenen die angezeigt werden. Die Anzeige
-    beginnt ab der in $aStart festgelegten Ebene, bis hin zu der hier
-    festgelegten Ebene.
-
-        SM2_ALL      Keine Beschränkung, alle Ebenen werden angezeigt
-
-        SM2_CURR+N   Zeigt immer die aktuelle Seite + N Ebenen.
-                     SM2_CURR      Aktuelle Ebene (keine Unterebene)
-                     SM2_CURR+3    Alle übergeordneten + aktuelle + 3 Unterebenen
-
-        SM2_START+N  Beginnt immer auf der Startebene + N Ebenen.
-                     Die Ebenen werden unabhängig davon angezeigt,egal
-                     auf welcher Ebene sich die aktuelle Seite befindet.
-                     SM2_START     Eine einzelne Ebene ab der Startebene.
-                     SM2_START+1   Startebene + eine Ebene darunter.
-
-        SM2_MAX+N    Zeigt höchstens N Ebenen ab der Startebene.
-                     Ebenen unterhalb der aktuellen Ebene werden nicht angezeigt.
-                     SM2_MAX       Nur die Startebene (gleiche Wirkung wie SM2_START)
-                     SM2_MAX+1     Die Startebene und eine Ebene darunter.
-
-$aOptions
-    Spezielle Flags für verschiedene Menügenerierungs Optionen. Sie können mittels
-    einer ODER Verknüpfung (|) miteinander kombiniert werden. Um beispielsweise
-    sowohl TRIM als auch PRETTY zu definieren, verwendet man: (SM2_TRIM | SM2_PRETTY).
-
-    GROUP 1
-    -------
-    Aus dieser Gruppe muss stets genau ein Flag angegeben werden. Diese Flags
-    bestimmen auf welche Weise die Geschwisterelemente im Menübaum in der
-    Ausgabe unterdrückt werden.
-
-    SM2_ALL         Zeigt alle Zweige des Menübaums
-                        A-1 -> B-1
-                            -> B-2 -> C-1
-                                   -> C-2 (CURRENT)
-                                          -> D-1
-                                          -> D-2
-                                   -> C-3
-                        A-2 -> B-3
-                            -> B-4
-
-    SM2_TRIM        Zeigt alle Geschwistermenüs der Seite im aktuellen Pfad.
-                    Alle Untermenüs von Elemnten die sich nicht im Pfad befinden
-                    werden entfernt.
-                        A-1 -> B-1
-                            -> B-2 -> C-1
-                                   -> C-2 (CURRENT)
-                                          -> D-1
-                                          -> D-2
-                                   -> C-3
-                        A-2
-
-    SM2_CRUMB       Zeigt den Breadcrumb Pfad des Menüs an, also den aktuellen
-                    Menüpunkt sowie alle Menüpunkte die dorthin führen.
-                        A-1 -> B-2 -> C-2 (CURRENT)
-
-    SM2_SIBLING     Wie SM2_TRIM, es werden aber nur Geschwistermenüs der aktuellen
-                    Seite angezeigt. Alle anderen Punkte werden unterdrückt.
-                        A-1 -> B-2 -> C-1
-                                   -> C-2 (CURRENT)
-                                          -> D-1
-                                          -> D-2
-                                   -> C-3
-
-    GROUP 2
-    -------
-    Diese Flags sind optional, sie können in beliebiger Anzahl kombiniert werden.
-
-    SM2_NUMCLASS    Fügt die nummerierten Menüklassen "menu-N" und
-                    "menu-child-N hinzu.
-
-    SM2_ALLINFO     Lädt alle Felder aus der Seitentabelle der Datenbank.
-                    Dies verursacht einen ziemlich hohen Speicherverbauch und sollte
-                    deshalb nur mit Bedacht verwendet werden.
-                    Dadurch werden z.B. die Keywords, die Seitenbeschreibung sowie
-                    all die anderen Informationen verfügbar, die normalerweise nicht
-                    geladen werden.
-                    Bitte beachten: dieses Flag muss beim ERSTEN Aufruf von schow_menu2
-                    für die jeweilige Menü ID verwendet werden, oder in Verbindung
-                    mit SM2_NOCACHE, sonst zeigt es keine Wirkung.
-
-    SM2_NOCACHE     Die aus der Datenbank gelesenen Daten werden bei erneutem Aufruf von
-                    show_menu2 nicht wiederverwendet sondern erneut aus der Datenbank
-                    gelesen.
-
-    SM2_PRETTY      Bringt die HTML-Ausgabe des Menüs mittels Leerzeichen und
-                    Zeilenumbrüchen in eine gut lesbare Form. Das ist besonders
-                    nützlich beim Debuggen der Menüausgabe.
-
-    SM2_BUFFER      Gibt den HTML-Code nicht direkt aus, sondern speichert ihn intern
-                    zwischen und gibt ihn als kompletten String aus.
-
-    SM2_CURRTREE    Schliesst alle anderen Toplevelmenüs von der Betrachtung aus.
-                    Es werden nur Menüpunkte des aktuellen Menüzweiges dargestellt.
-                    Dieses Flag kann bei Bedarf mit jedem Flag aus der Gruppe 1
-                    kombiniert werden.
-
-    SM2_ESCAPE      Wendet htmlspecialchars auf den Menüstring an.
-                    Dies kann bei älteren Websitebaker Installationen erforderlich
-                    sein um eine valide HTML Ausgabe zu erzeugen.
-
-    SM2_SHOWHIDDEN  Hidden pages are usually hidden all of the time, including
-                    when they are active (i.e. current page or a parent page).
-                    Use private pages for time when you want pages to be
-                    hidden except when active. However for compatibility with
-                    release 4.8, supply this flag to enable hidden pages to
-                    become visible when they are active.
-
-    SM2_XHTML_STRICT	Stellt die XHTML-Kompatibilität der Links sicher indem
-					in per [a] oder [ac] formatierten Links die Targetangabe
-					entfernt und das Argument title="[page_titel]" eingefügt
-					wird. Bei manuell zusammengestellten Links ist der Designer
-					selbst für die XHTML-Konformität zuständig.
-
-	SM2_NO_TITLE	Unterdrückt die Ausgabe des Inhaltes des Title-Attributes
-					bei [a] oder [ac] formatierten links. Im XHTML-Strikt Modus
-                    wird 'title' mit einen &nbsp; ausgegeben.
-
-    Für diesen Parameter gibt es auch einen erweiterten Modus, bei dem die Optionen
-    als assoziatives Array übergeben werden. Näheres dazu im Abschnitt ERWEITERTE
-    OPTIONEN. Für die meisten Anwendungsfälle wird dies jedoch NICHT benötigt.
-
-$aItemOpen
-    Dies legt den Formatstring fest, mit dem jeder einzelne Menüeintrag begonnen
-    wird. Für den allerersten Menüeintrag kann mittels $aTopItemOpen ein anderer
-    Formatstring definiert werden.
-    Wenn dieser Parameter auf false gesetzt wird, wird der Vorgabe Formatstring
-    '[li][a][menu_title]</a>' verwendet um die Kompatibilität zur Website Baker
-    Standardfunktion show_menu() zu gewährleisten.
-    Da die Formatierung mittels CSS-Klassen oftmals einfacher ist, wenn sie auf den
-    <a> tag angewendet werden, empfiehlt es sich hier folgenden Formatstring zu
-    verwenden: '<li>[ac][menu_title]</a>'.
-
-    Dieser Parameter kann auch als Instanz eine Formatierungklasse für das Menü
-    verwendet werden. Die nähere Beschreibung dazu findet sich im Abschnitt FORMATTER.
-    Wenn hier ein Formatter angegeben wird, werden alle Argumente
-    nach $aItemOpen ignoriert.
-
-$aItemClose
-    Dieser String schließt jeden Menüpunkt ab.
-    Bitte beachten: dies ist kein Formatstring und es werden keine Schlüsselworte
-    ersetzt!
-    Wenn dieser Parameter auf false gesetzt ist, wird die Vorgabe '</li>' verwendet.
-
-$aMenuOpen
-    Mit diesem Formatstring wird eine Liste von Menüeinträgen geöffnet. Für das erste
-    Menü kann mittels $aTopMenuOpen ein davon abweichender Formatstring definiert
-    werden.
-    Wenn dieser Parameter auf false gesetzt ist wird der Vorgabewert '[ul]'
-    verwendet.
-
-$aMenuClose
-    Dieser String schließt jedes Menü ab.
-    Bitte beachten: dies ist kein Formatstring und es werden keine Schlüsselworte
-    ersetzt!
-    Wenn dieser Parameter auf false gesetzt ist, wird die Vorgabe '</ul>' verwendet.
-
-$aTopItemOpen
-    Der Formatstring für den allerersten Menüpunkt. Wenn dieser Parameter auf false
-    gesetzt wird, wird der selbe Formatstring wie bei $aItemOpen verwendet.
-
-$aTopMenuOpen
-    Der Formatstring für das erste Menü. Wenn dieser Parameter auf false
-    gesetzt wird, wird der selbe Formatstring wie bei $aMenuOpen verwendet.
-
-
-
-ERWEITERTE OPTIONEN
-===================
-Der Parameter $aOptions kann auf zweierlei Arten verwendet werden. Zum einen, wie oben
-im Abschnitt PARAMETER beschrieben, diese Art sollte für die allermeisten
-Anwendungsfälle ausreichen. Um allerdings in speziellen Fällen die Sonderoptionen
-ansprechen zu können, müssen die erforderlichen Werte als assoziatives Array
-bereitgestellt werden.
-Bitte beachten: Die SM2_* Flags sind auch hierbei erforderlich und müßen als 'flags'
-übergeben werden.
-
-    'flags'     **ZWINGEND ERFORDELICH** Dies sind die Flags die oben im Abschnitt
-                PARAMETER unter $aOptions beschrieben wurden.
-
-    'notrim'    Hiermit wird eine Anzahl von Ebenen festegelegt, die relativ bezogen
-                auf die in $aStart festgelegte Menüebene, immer angezeigt werden. Dies
-                bewirkt, daß für diese Ebenen das SM2_TRIM Flag ignoriert wird.
-
-Um dieses Array zu verwenden, empfiehlt es sich es erst anzulegen und dann den
-$aOptions parameter mit dem angelegten Array zu beliefern:
-
-    $options = array('flags' => (SM2_TRIM|...), 'notrim' => 1);
-    show_menu2(0, SM2_ROOT, SM2_CURR+1, $options);
-
-
-
-FORMAT STRINGS
-==============
-Die folgenden Tags können in den Formatstrings für $aItemOpen und $aMenuOpen
-verwendet werden und sollen durch den entsprechenden Text ersetzt werden.
-
-[a]             <a> tag ohne Klasse:   '<a href="[url]" target="[target]">'
-[ac]            <a> tag mit Klasse:    '<a href="[url]" target="[target]" class="[class]">'
-[li]            <li> tag mit Klasse:   '<li class="[class]">'
-[ul]            <ul> tag mit Klasse:   '<ul class="[class]">'
-[class]         Liste der Klassen für diese Seite
-[menu_title]    Text des Menütitel
-                (HTML entity escaped ausser das SM2_NOESCAPE Flag ist gesetzt)
-[menu_icon_0]	die URL zu einer Bilddatei mit normal - Darstellung (ab WB2.8.4)
-[menu_icon_1]	die URL zu einer Bilddatei mit active/hover - Darstellung (ab WB2.8.4)
-[page_title]    text des Seitentitel
-                (HTML entity escaped ausser das SM2_NOESCAPE Flag ist gesetzt)
-[page_icon]		die URL zu einer seitenbezogenen Bilddatei (ab WB2.8.4)
-[tooltip]       Tooltip-Text, der normal im title-Attribut der Links ausgegeben wird (ab WB2.8.4)
-[url]           die URL der Seiten für den <a> tag
-[target]        das Seitenziel für den <a> tag
-[page_id]       die Page ID des aktuellen Menüpunktes.
-[parent]        die Page ID des übergeordneten Menüpunktes.
-[level]         die Seitenebene,
-                dies ist die gleiche Zahl die im "menu-N" CSS tag verwendet wird.
-[sib]           Anzahl der Geschwister des aktuellen Menüpunktes.
-[sibCount]      Anzahl aller Geschwister in diesem Menü.
-[if]            Bedingung (Details hierzu im Abschnitt "Bedingte Formatierung')
-
-Folgende tags sind NUR verfügbar, wenn das SM2_ALLINFO Flag gesetzt ist.
-
-[description]   Seitenbeschreibung
-[keywords]      Schlüsselworte der Seite
-
-
-
-BEDINGTE FORMATIERUNG
-=====================
-Die Anweisung für eine bedingte Formatierung kann eine der folgenden Formen haben:
-
-    [if(A){B}]
-    [if(A){B}else{C}]
-
-    A   Die Bedingung. Details dazu, siehe unten.
-
-    B   Der Ausdruck der verwendet wird, wenn die Bedingung erfüllt ist.
-        Dies kann ein beliebiger String sein, der jedoch nicht das Zeichen '}'
-        enthalten darf. Er kann jeden beliebigen Formatstring aus dem Abschnitt
-        'Format Strings' enthalten, jedoch keinen weiteren Bedingungstest (da das
-        Zeichen '}' nicht erlaubt ist).
-
-    C   Der Ausdruck der verwendet wird, wenn die Bedingung nicht erfüllt ist.
-        Dies kann ein beliebiger String sein, der jedoch nicht das Zeichen '}'
-        enthalten darf. Er kann jeden beliebigen Formatstring aus dem Abschnitt
-        'Format Strings' enthalten, jedoch keinen weiteren Bedingungstest (da das
-        Zeichen '}' nicht erlaubt ist).
-
-Die Bedingung ist eine Kombination von einem oder mehreren boolschen Vergleichen.
-Wenn mehr als ein Vergleich erforderlich ist, so muss dieser mit den anderen Vergleichen
-mittels || (boolsches oder - OR) oder && (boolsches und - AND) verknüpft werden.
-
-Ein einzelner Vergleich besteht aus dem linken Operanden, dem Operator und dem rechten
-Operanden.
-z.B. X == Y  - hierbei ist X der linke Operand, == der Operator und Y der rechte Operand.
-
-    Linker Operand. Muss eines der folgende Schlüsselworte sein:
-        class       Überprüfung ob diese Klasse existiert. Es sind nur die
-                    "==" and "!=" Operatoren erlaubt. In diesem Fall haben die Operatoren
-                    die Bedeutung von "enthält" bzw. "enthält nicht" an Stelle von
-                    "ist gleich" bzw. "ist nicht gleich"
-        level       Überprüfung der Seitenebene.
-        sib         Überprüfung der Geschwisteranzahl der aktuellen Seite.
-        sibCount    Überprüfung der Geamtanzahl der Geschwister im aktuellen Menü.
-        id          Überprüfung der page id.
-		target		Überprüfung der Target-Angabe
-
-    Operator. Muss einer der folgenden sein:
-        <           Kleiner als
-        <=          Kleiner oder gleich als
-        ==          Gleich
-        !=          Nicht gleich
-        >=          Grössr oder gleich als
-        >           Grösser als
-
-    Rechter Operand. Die Art dieses Operanden hängt von dem, für den linken Operanden
-                     verwendeten Schlüsselwort ab.
-        class       einer der "menu-*" Klassennamen wie sie im Abschnitt "Ausgabe"
-                    spezifiziert sind.
-        level       Überprüfung der Seitenebene gegen folgende Werte:
-                        <number>  die absolute Seitenebene
-                        root      die oberste Seitenebene
-                        granny    die Seitenebene über der übergeordneten Seitenebene
-                        parent    die übergeordnete Seitenebene
-                        current   die aktuelle Seitenebene
-                        child     die untergeornete Seitenebene
-        id          Überprüfung der page id gegen folgende Werte:
-                        <number>  die absolute page id
-                        parent    die übergeordnete page id
-                        current   die aktuelle page id
-        sib         Eine positive Integerzahl, oder "sibCount" um die Anzahl der
-                    Geschwister in diesem Menü zu überprüfen
-        sibCount    Eine positive Integerzahl
-		target		Ein String, der eine mögliche Targetangabe darstellt
-
-Folgende Beispiele ergeben "wahr" und der Ausdruck {exp} wird ausgeführt, wenn zutrifft:
-
-    [if(class==menu-expand){exp}]   hat ein Untermenü
-    [if(class==menu-first){exp}]    ist der erste Eintrag in einem Menü
-    [if(class!=menu-first){exp}]    ist NICHT der erste Eintrag in einem Menü
-    [if(class==menu-last){exp}]     ist der letzte Eintrag in einem Menü
-    [if(level==0){exp}]             befindet sich auf der obersten Ebene
-    [if(level>0){exp}]              befindet sich NICHT auf der obersten Ebene
-    [if(sib==2){exp}]               ist der zweite Eintrag in einem Menü
-    [if(sibCount>1){exp}]           ist in einem Menü mit mehr als einem Eintrag
-    [if(sibCount!=2){exp}]          ist in einem Menü, das nicht genau 2 Einträge hat
-    [if(level>parent){exp}]         ist in einem Geschwistermenü oder dem Untermenü eines
-                                    Geschwistermenüs
-    [if(id==parent){exp}]           ist der übergeordnete Punkt der aktuellen id
-	[if(target==_self){exp}]		im Target-Attribut ist der String '_self' enthalten
-
-Wenn eine sonst-Klausel (else) hinzugefügt wird, so wird diese in allen anderen Fällen
-ausgeführt.
-Zum Beispiel wird "foo" immer dann ausgeführt, wenn die if Überprüfung falsch ergibt, also:
-
-    [if(sib==2){exp}else{foo}]      ist NICHT der zweite Eintrag im Menü
-    [if(sibCount>2){exp}else{foo}]  ist NICHT in einem Menü mit mehr als zwei Einträgen
-
-Bei mehrfach Vergleichen wird der Ausdruck "exp" nur ausgeführt, wenn:
-
-    [if(sib == 1 || sib > 3){exp}]  ist der erste Eintrag ODER ist der vierte oder höhere
-    Eintrag im Menü
-
-    [if(id == current && class == menu-expand){exp}  ist der aktuelle Eintrag UND hat
-    Untermenüs
-
-Bitte beachten:
-Alle Überprüfungen werden in der Reihenfolge ausgeführt, in der sie notiert sind, denn:
-* es findet keine Überprüfung auf evtl. Schleifen statt (alle Überprüfungen werden immer ausgeführt)
-* Überprüfungen werden nicht gruppiert (eine Klammerung von Überprüfungen wird nicht unterstützt)
-* sowohl || als auch && haben die gleiche Wertigkeit
-
-
-
-FORMATTER
-=========
-Achtung: dies ist ein fortgeschrittenes und äusserst selten benötigtes Feature!
-
-Mit umfangreichen Kenntnissen in der PHP Programmierung ist es möglich den vordefinierten
-Formatierer von show_menu2 mit einem eigenen zu ersetzen.
-In der include.php von show_menu2 sieht man wie der Formatierer geschreiben werden muss.
-Die API, die verwendet werden muss, sieht wie folgt aus:
-
-(Anmerkung des Übersetzers: Kommentare sind nicht übersetzt, wer sich so weit vorwagt, sollte
-damit keine Probleme haben ;-)
-
-class SM2_Formatter
-{
-    // called once before any menu is processed to allow object initialization
-    function initialize() { }
-
-    // called to open the menu list
-    function startList($aPage, $aUrl) { }
-
-    // called to open the menu item
-    function startItem($aPage, $aUrl, $aCurrSib, $aSibCount) { }
-
-    // called to close the menu item
-    function finishItem() { }
-
-    // called to close the menu list
-    function finishList() { }
-
-    // called once after all menu has been processed to allow object finalization
-    function finalize() { }
-
-    // called once after finalize() if the SM2_NOOUTPUT flag is used
-    function getOutput() { }
-};

Property changes on: branches/2.8.x/wb/modules/show_menu2/README.de.txt
___________________________________________________________________
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/include.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/include.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/include.php	(nonexistent)
@@ -1,861 +0,0 @@
-<?php
-/**
- *
- * @category        module
- * @package         show_menu2
- * @author          WebsiteBaker Project
- * @copyright       Brodie Thiesfield
- * @copyright       2009-2013, WebsiteBaker Org. e.V.
- * @link            http://www.websitebaker.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.7.0 | 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-// Must include code to stop this file being access directly
-if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
-
-/**
- * future replacement for the function show_menu2()
- */
-class SM2
-{
-    const ROOT =          -1000;
-    const CURR =          -2000;
-    const ALLMENU =          -1;
-    const START =          1000;
-    const MAX =            2000;
-    const ALL =          0x0001; // bit 0 (group 1) (Note: also used for max level!)
-    const TRIM =         0x0002; // bit 1 (group 1)
-    const CRUMB =        0x0004; // bit 2 (group 1)
-    const SIBLING =      0x0008; // bit 3 (group 1)
-    const NUMCLASS =     0x0010; // bit 4
-    const ALLINFO =      0x0020; // bit 5
-    const NOCACHE =      0x0040; // bit 6
-    const PRETTY =       0x0080; // bit 7
-    const ESCAPE =       0x0100; // bit 8
-    const NOESCAPE =          0; // NOOP, unnecessary with WB 2.6.7+
-    const BUFFER =       0x0200; // bit 9
-    const CURRTREE =     0x0400; // bit 10
-    const SHOWHIDDEN =   0x0800; // bit 11
-    const XHTML_STRICT = 0x1000; // bit 12
-    const NO_TITLE =     0x2000; // bit 13
-    const _GROUP_1 =     0x000F; // exactly one flag from group 1 is required
-    const CONDITIONAL =  'if\s*\(([^\)]+)\)\s*{([^}]*)}\s*(?:else\s*{([^}]*)}\s*)?';
-    const COND_TERM =    '\s*(\w+)\s*(<|<=|==|=|=>|>|!=)\s*([\w\-]+)\s*';
-}
-
-// Implement support for page_menu and show_menu using show_menu2. If you remove
-// the comments characters from the beginning of the following include, all menu
-// functions in Website Baker will be implemented using show_menu2. While it is
-// commented out, the original WB functions will be used.
-//include('legacy.php');
-
-// This class is the default menu formatter for sm2. If desired, you can
-// create your own formatter class and pass the object into show_menu2
-// as $aItemFormat.
-
-
-class SM2_Formatter
-{
-    var $output;
-    var $flags;
-    var $itemOpen;
-    var $itemClose;
-    var $menuOpen;
-    var $menuClose;
-    var $topItemOpen;
-    var $topMenuOpen;
-
-    var $isFirst;
-    var $page;
-    var $url;
-    var $currSib;
-    var $sibCount;
-    var $currClass;
-    var $prettyLevel;
-
-    // output the data
-    function output($aString) {
-        if ($this->flags & SM2::BUFFER) {
-            $this->output .= $aString;
-        }
-        else {
-            echo $aString;
-        }
-    }
-
-    // set the default values for all of our formatting items
-    function set($aFlags, $aItemOpen, $aItemClose, $aMenuOpen, $aMenuClose, $aTopItemOpen, $aTopMenuOpen) {
-        $this->flags        = $aFlags;
-        $this->itemOpen     = is_string($aItemOpen)    ? $aItemOpen    : '[li][a][menu_title]</a>';
-        $this->itemClose    = is_string($aItemClose)   ? $aItemClose   : '</li>';
-        $this->menuOpen     = is_string($aMenuOpen)    ? $aMenuOpen    : '[ul]';
-        $this->menuClose    = is_string($aMenuClose)   ? $aMenuClose   : '</ul>';
-        $this->topItemOpen  = is_string($aTopItemOpen) ? $aTopItemOpen : $this->itemOpen;
-        $this->topMenuOpen  = is_string($aTopMenuOpen) ? $aTopMenuOpen : $this->menuOpen;
-    }
-
-    // initialize the state of the formatter before anything is output
-    function initialize() {
-        $this->output = '';
-        $this->prettyLevel = 0;
-        if ($this->flags & SM2::PRETTY) {
-            $this->output("\n<!-- show_menu2 -->");
-        }
-    }
-
-    // start a menu
-    function startList(&$aPage, &$aUrl) {
-        $currClass = '';
-        $currItem = $this->menuOpen;
-
-        // use the top level menu open if this is the first menu
-        if ($this->topMenuOpen) {
-            $currItem = $this->topMenuOpen;
-            $currClass .= ' menu-top';
-            $this->topMenuOpen = false;
-        }
-
-        // add the numbered menu class only if requested
-        if (($this->flags & SM2::NUMCLASS) == SM2::NUMCLASS) {
-            $currClass .= ' menu-'.$aPage['level'];
-        }
-
-        $this->prettyLevel += 1;
-
-        // replace all keywords in the output
-        if ($this->flags & SM2::PRETTY) {
-            $this->output("\n".str_repeat(' ',$this->prettyLevel).
-                $this->format($aPage, $aUrl, $currItem, $currClass));
-        }
-        else {
-            $this->output($this->format($aPage, $aUrl, $currItem, $currClass));
-        }
-
-        $this->prettyLevel += 3;
-    }
-
-    // start an item within the menu
-    function startItem(&$aPage, &$aUrl, $aCurrSib, $aSibCount) {
-        // generate our class list
-        $currClass = '';
-        if (($this->flags & SM2::NUMCLASS) == SM2::NUMCLASS) {
-            $currClass .= ' menu-'.$aPage['level'];
-        }
-        if (array_key_exists('sm2_has_child', $aPage)) {
-            // not set if false, so existence = true
-            $currClass .= ' menu-expand';
-        }
-        if (array_key_exists('sm2_is_curr', $aPage)) {
-            $currClass .= ' menu-current';
-        }
-        elseif (array_key_exists('sm2_is_parent', $aPage)) {
-            // not set if false, so existence = true
-            $currClass .= ' menu-parent';
-        }
-        elseif (array_key_exists('sm2_is_sibling', $aPage)) {
-            // not set if false, so existence = true
-            $currClass .= ' menu-sibling';
-        }
-        elseif (array_key_exists('sm2_child_level',$aPage)) {
-            // not set if not a child
-            $currClass .= ' menu-child';
-            if (($this->flags & SM2::NUMCLASS) == SM2::NUMCLASS) {
-                $currClass .= ' menu-child-'.($aPage['sm2_child_level']-1);
-            }
-        }
-        if ($aCurrSib == 1) {
-            $currClass .= ' menu-first';
-        }
-        if ($aCurrSib == $aSibCount) {
-            $currClass .= ' menu-last';
-        }
-
-        // use the top level item if this is the first item
-        $currItem = $this->itemOpen;
-        if ($this->topItemOpen) {
-            $currItem = $this->topItemOpen;
-            $this->topItemOpen = false;
-        }
-
-        // replace all keywords in the output
-        if ($this->flags & SM2::PRETTY) {
-            $this->output("\n".str_repeat(' ',$this->prettyLevel));
-        }
-        $this->output($this->format($aPage, $aUrl, $currItem, $currClass, $aCurrSib, $aSibCount));
-    }
-
-    // find and replace all keywords, setting the state variables first
-    function format(&$aPage, &$aUrl, &$aCurrItem, &$aCurrClass,
-        $aCurrSib = 0, $aSibCount = 0)
-    {
-        $this->page      = &$aPage;
-        $this->url       = &$aUrl;
-        $this->currClass = trim($aCurrClass);
-        $this->currSib   = $aCurrSib;
-        $this->sibCount  = $aSibCount;
-
-        $item = $this->format2($aCurrItem);
-
-        unset($this->page);
-        unset($this->url);
-        unset($this->currClass);
-
-        return $item;
-    }
-
-    // find and replace all keywords
-    function format2(&$aCurrItem) {
-        if (!is_string($aCurrItem)) return '';
-        return preg_replace_callback(
-            '@\[('.
-                'a|ac|/a|li|/li|ul|/ul|menu_title|menu_icon_0|menu_icon_1|'.
-                'page_title|page_icon|url|target|page_id|tooltip|'.
-                'parent|level|sib|sibCount|class|description|keywords|'.
-                SM2::CONDITIONAL.
-            ')\]@',
-            array($this, 'replace'),
-            $aCurrItem);
-    }
-
-    // replace the keywords
-    function replace($aMatches) {
-        $aMatch = $aMatches[1];
-        $retval = '['.$aMatch.'=UNKNOWN]';
-        switch ($aMatch) {
-        case 'a':
-            $retval = '<a href="'.$this->url.'"';
-            // break; // ignore 'break' to add the rest of <a>-tag
-        case 'ac':
-            if( substr($retval, 0, 2) != '<a'){
-                $retval = '<a href="'.$this->url.'" class="'.$this->currClass.'"';
-            }
-            if(($this->flags & SM2::NO_TITLE)) {
-                $retval .= ' title="'.$this->page['tooltip'].'"';
-            }
-            if(!($this->flags & SM2::XHTML_STRICT)) {
-                $retval .= ' target="'.$this->page['target'].'"';
-            }
-            $retval .= '>';
-            break;
-        case '/a':
-            $retval = '</a>'; break;
-        case 'li':
-            $retval = '<li class="'.$this->currClass.'">'; break;
-        case '/li':
-            $retval = '</li>'; break;
-        case 'ul':
-            $retval = '<ul class="'.$this->currClass.'">'; break;
-        case '/ul':
-            $retval = '</ul>'; break;
-        case 'url':
-            $retval = $this->url; break;
-        case 'sib':
-            $retval = $this->currSib; break;
-        case 'sibCount':
-            $retval = $this->sibCount; break;
-        case 'class':
-            $retval = $this->currClass; break;
-        default:
-            if (array_key_exists($aMatch, $this->page)) {
-                if ($this->flags & SM2::ESCAPE) {
-                    $retval = htmlspecialchars($this->page[$aMatch], ENT_QUOTES);
-                }
-                else {
-                    $retval = $this->page[$aMatch];
-                }
-            }
-            if (preg_match('/'.SM2::CONDITIONAL.'/', $aMatch, $rgMatches)) {
-                $retval = $this->replaceIf($rgMatches[1], $rgMatches[2], $rgMatches[3]);
-            }
-        }
-        return $retval;
-    }
-
-    // conditional replacement
-    function replaceIf(&$aExpression, &$aIfValue, &$aElseValue) {
-        // evaluate all of the tests in the conditional (we don't do short-circuit
-        // evaluation) and replace the string test with the boolean result
-        $rgTests = preg_split('/(\|\||\&\&)/', $aExpression, -1, PREG_SPLIT_DELIM_CAPTURE);
-        for ($n = 0; $n < count($rgTests); $n += 2) {
-            if (preg_match('/'.SM2::COND_TERM.'/', $rgTests[$n], $rgMatches)) {
-                $rgTests[$n] = $this->ifTest($rgMatches[1], $rgMatches[2], $rgMatches[3]);
-            }
-            else {
-                @error_logs("show_menu2 error: conditional expression is invalid!");
-                $rgTests[$n] = false;
-            }
-        }
-
-        // combine all test results for a final result
-        $ok = $rgTests[0];
-        for ($n = 1; $n+1 < count($rgTests); $n += 2) {
-            if ($rgTests[$n] == '||') {
-                $ok = $ok || $rgTests[$n+1];
-            }
-            else {
-                $ok = $ok && $rgTests[$n+1];
-            }
-        }
-
-        // return the formatted expression if the test succeeded
-        return $ok ? $this->format2($aIfValue) : $this->format2($aElseValue);
-    }
-
-    // conditional test
-    function ifTest(&$aKey, &$aOperator, &$aValue) {
-        global $wb;
-
-        // find the correct operand
-        $operand = false;
-        switch($aKey) {
-        case 'class':
-            // we need to wrap the class names in spaces so we can test for a unique
-            // class name that will not match prefixes or suffixes. Same must be done
-            // for the value we are testing.
-            $operand = " $this->currClass ";
-            break;
-        case 'target':
-            $operand = $this->page['target'];
-            break;
-        case 'sib':
-            $operand = $this->currSib;
-            if ($aValue == 'sibCount') {
-                $aValue = $this->sibCount;
-            }
-            break;
-        case 'sibCount':
-            $operand = $this->sibCount;
-            break;
-        case 'level':
-            $operand = $this->page['level'];
-            switch ($aValue) {
-            case 'root':    $aValue = 0; break;
-            case 'granny':  $aValue = $wb->page['level']-2; break;
-            case 'parent':  $aValue = $wb->page['level']-1; break;
-            case 'current': $aValue = $wb->page['level'];   break;
-            case 'child':   $aValue = $wb->page['level']+1; break;
-            }
-            if ($aValue < 0) $aValue = 0;
-            break;
-        case 'id':
-            $operand = $this->page['page_id'];
-            switch ($aValue) {
-            case 'parent':  $aValue = $wb->page['parent'];  break;
-            case 'current': $aValue = $wb->page['page_id']; break;
-            }
-            break;
-        default:
-            return '';
-        }
-
-        // do the test
-        $ok = false;
-        switch ($aOperator) {
-        case '<':
-            $ok = ($operand < $aValue);
-            break;
-        case '<=':
-            $ok = ($operand <= $aValue);
-            break;
-        case '=':
-        case '==':
-        case '!=':
-            if ($aKey == 'class') {
-                $ok = strstr($operand, " $aValue ") !== FALSE;
-            }
-            else {
-                $ok = ($operand == $aValue);
-            }
-            if ($aOperator == '!=') {
-                $ok = !$ok;
-            }
-            break;
-        case '>=':
-            $ok = ($operand >= $aValue);
-        case '>':
-            $ok = ($operand > $aValue);
-        }
-
-        return $ok;
-    }
-
-    // finish the current menu item
-    function finishItem() {
-        if ($this->flags & SM2::PRETTY) {
-            $this->output(str_repeat(' ',$this->prettyLevel).$this->itemClose);
-        }
-        else {
-            $this->output($this->itemClose);
-        }
-    }
-
-    // finish the current menu
-    function finishList() {
-        $this->prettyLevel -= 3;
-
-        if ($this->flags & SM2::PRETTY) {
-            $this->output("\n".str_repeat(' ',$this->prettyLevel).$this->menuClose."\n");
-        }
-        else {
-            $this->output($this->menuClose);
-        }
-
-        $this->prettyLevel -= 1;
-    }
-
-    // cleanup the state of the formatter after everything has been output
-    function finalize() {
-        if ($this->flags & SM2::PRETTY) {
-            $this->output("\n");
-        }
-    }
-
-    // return the output
-    function getOutput() {
-        return $this->output;
-    }
-};
-
-function error_logs($error_str)
-{
-                $log_error = true;
-                if ( ! function_exists('error_log') )
-                        $log_error = false;
-
-                $log_file = @ini_get('error_log');
-                if ( !empty($log_file) && ('syslog' != $log_file) && !@is_writable($log_file) )
-                        $log_error = false;
-
-                if ( $log_error )
-                        @error_log($error_str, 0);
-}
-
-function show_menu2(
-    $aMenu          = 0,
-    $aStart         = SM2::ROOT,
-    $aMaxLevel      = -1999, // SM2::CURR+1
-    $aOptions       = SM2::TRIM,
-    $aItemOpen      = false,
-    $aItemClose     = false,
-    $aMenuOpen      = false,
-    $aMenuClose     = false,
-    $aTopItemOpen   = false,
-    $aTopMenuOpen   = false
-    )
-{
-    global $wb;
-    $database = WbDatabase::getInstance();
-    $iQueryStart = $database->getQueryCount;
-    // extract the flags and set $aOptions to an array
-    $flags = 0;
-    if (is_int($aOptions)) {
-        $flags = $aOptions;
-        $aOptions = array();
-    }
-    else if (isset($aOptions['flags'])) {
-        $flags = $aOptions['flags'];
-    }
-    else {
-        $flags = SM2::TRIM;
-        $aOptions = array();
-        @error_logs('show_menu2 error: $aOptions is invalid. No flags supplied!');
-    }
-
-    // ensure we have our group 1 flag, we don't check for the "exactly 1" part, but
-    // we do ensure that they provide at least one.
-    if (0 == ($flags & SM2::_GROUP_1)) {
-        @error_logs('show_menu2 error: $aOptions is invalid. No flags from group 1 supplied!');
-        $flags |= SM2::TRIM; // default to TRIM
-    }
-
-    // search page results don't have any of the page data loaded by WB, so we load it
-    // ourselves using the referrer ID as the current page
-    $CURR_PAGE_ID = defined('REFERRER_ID') ? REFERRER_ID : PAGE_ID;
-    if (count($wb->page) == 0 && defined('REFERRER_ID') && REFERRER_ID > 0) {
-        global $database;
-        $sql = 'SELECT * FROM `'.TABLE_PREFIX.'pages` WHERE `page_id` = '.REFERRER_ID.'';
-        $result = $database->query($sql);
-        if ($result->numRows() == 1) {
-            $wb->page = $result->fetchRow();
-        }
-        unset($result);
-    }
-
-    // fix up the menu number to default to the menu number
-    // of the current page if no menu has been supplied
-    if ($aMenu == 0) {
-        $aMenu = $wb->page['menu'] == '' ? 1 : $wb->page['menu'];
-    }
-
-    // Set some of the $wb->page[] settings to defaults if not set
-    $pageLevel  = $wb->page['level']  == '' ? 0 : $wb->page['level'];
-    $pageParent = $wb->page['parent'] == '' ? 0 : $wb->page['parent'];
-
-    // adjust the start level and start page ID as necessary to
-    // handle the special values that can be passed in as $aStart
-    $aStartLevel = 0;
-    if ($aStart < SM2::ROOT) {   // SM2::CURR+N
-        if ($aStart == SM2::CURR) {
-            $aStartLevel = $pageLevel;
-            $aStart = $pageParent;
-        }
-        else {
-            $aStartLevel = $pageLevel + $aStart - SM2::CURR;
-            $aStart = $CURR_PAGE_ID;
-        }
-    }
-    elseif ($aStart < 0) {   // SM2::ROOT+N
-        $aStartLevel = $aStart - SM2::ROOT;
-        $aStart = 0;
-    }
-
-    // we get the menu data once and store it in a global variable. This allows
-    // multiple calls to show_menu2 in a single page with only a single call to
-    // the database. If this variable exists, then we have already retrieved all
-    // of the information and processed it, so we don't need to do it again.
-    if (($flags & SM2::NOCACHE) != 0
-        || !array_key_exists('show_menu2_data', $GLOBALS)
-        || !array_key_exists($aMenu, $GLOBALS['show_menu2_data']))
-    {
-        global $database;
-
-        // create an array of all parents of the current page. As the page_trail
-        // doesn't include the theoretical root element 0, we add it ourselves.
-        $rgCurrParents = explode(",", '0,'.$wb->page['page_trail']);
-        array_pop($rgCurrParents); // remove the current page
-        $rgParent = array();
-
-        // if the caller wants all menus gathered together (e.g. for a sitemap)
-        // then we don't limit our SQL query
-        $menuLimitSql = ' AND `menu`='.$aMenu;
-        if ($aMenu == SM2::ALLMENU) {
-            $menuLimitSql = '';
-        }
-
-        // we only load the description and keywords if we have been told to,
-        // this cuts the memory load for pages that don't use them. Note that if
-        // we haven't been told to load these fields the *FIRST TIME* show_menu2
-        // is called (i.e. where the database is loaded) then the info won't
-        // exist anyhow.
-        $fields  = '`parent`,`page_id`,`menu_title`,`page_title`,`link`,`target`,';
-        $fields .= '`level`,`visibility`,`viewing_groups`,`viewing_users`,';
-        $fields .= '`menu_icon_0`,`menu_icon_1`,`page_icon`,`tooltip`';
-        if ($flags & SM2::ALLINFO) {
-            $fields = '*';
-        }
-
-        // we request all matching rows from the database for the menu that we
-        // are about to create it is cheaper for us to get everything we need
-        // from the database once and create the menu from memory then make
-        // multiple calls to the database.
-        $sql  = 'SELECT '.$fields.' FROM `'.TABLE_PREFIX.'pages` ';
-        $sql .= 'WHERE '.$wb->extra_where_sql.' '.$menuLimitSql.' ';
-        $sql .= 'ORDER BY `level` ASC, `position` ASC';
-        $sql = str_replace('hidden', 'IGNOREME', $sql); // we want the hidden pages
-        $oRowset = $database->query($sql);
-        if (is_object($oRowset) && $oRowset->numRows() > 0) {
-            // create an in memory array of the database data based on the item's parent.
-            // The array stores all elements in the correct display order.
-            while ($page = $oRowset->fetchRow()) {
-                // ignore all pages that the current user is not permitted to view
-                if(version_compare(WB_VERSION, '2.7', '>=')) { // WB >= 2.7
-                    // 1. hidden pages aren't shown unless they are on the current page
-                    if ($page['visibility'] == 'hidden') {
-                        $page['sm2_hide'] = true;
-                    }
-
-                    // 2. all pages with no active sections (unless it is the top page) are ignored
-                    else if (!$wb->page_is_active($page) && $page['link'] != $wb->default_link && !INTRO_PAGE) {
-                        continue;
-                    }
-
-                    // 3. all pages not visible to this user (unless always visible to registered users) are ignored
-                    else if (!$wb->page_is_visible($page) && $page['visibility'] != 'registered') {
-                        continue;
-                    }
-                }
-                if(isset($page['page_icon']) && $page['page_icon'] != '') {
-                    $page['page_icon'] = WB_URL.$page['page_icon'];
-                }
-                if(isset($page['menu_icon_0']) && $page['menu_icon_0'] != '') {
-                    $page['menu_icon_0'] = WB_URL.$page['menu_icon_0'];
-                }
-                if(isset($page['menu_icon_1']) && $page['menu_icon_1'] != '') {
-                    $page['menu_icon_1'] = WB_URL.$page['menu_icon_1'];
-                }
-
-                if(!isset($page['tooltip'])) { $page['tooltip'] = $page['page_title']; }
-                // ensure that we have an array entry in the table to add this to
-                $idx = $page['parent'];
-                if (!array_key_exists($idx, $rgParent)) {
-                    $rgParent[$idx] = array();
-                }
-
-                // mark our current page as being on the current path
-                if ($page['page_id'] == $CURR_PAGE_ID) {
-                    $page['sm2_is_curr'] = true;
-                    $page['sm2_on_curr_path'] = true;
-                    if ($flags & SM2::SHOWHIDDEN)
-                    {
-                        // show hidden pages if active and SHOWHIDDEN flag supplied
-                        unset($page['sm2_hide']);
-                    }
-                }
-
-                // mark parents of the current page as such
-                if (in_array($page['page_id'], $rgCurrParents)) {
-                    $page['sm2_is_parent'] = true;
-                    $page['sm2_on_curr_path'] = true;
-                    if ($flags & SM2::SHOWHIDDEN)
-                    {
-                        // show hidden pages if active and SHOWHIDDEN flag supplied
-                        unset($page['sm2_hide']); // don't hide a parent page
-                    }
-                }
-
-                // add the entry to the array
-                $rgParent[$idx][] = $page;
-            }
-        }
-        unset($oRowset);
-
-        // mark all elements that are siblings of any element on the current path
-        foreach ($rgCurrParents as $x) {
-            if (array_key_exists($x, $rgParent)) {
-                foreach (array_keys($rgParent[$x]) as $y) {
-                    $mark =& $rgParent[$x][$y];
-                    $mark['sm2_path_sibling'] = true;
-                    unset($mark);
-                }
-            }
-        }
-
-        // mark all elements that have children and are siblings of the current page
-        $parentId = $pageParent;
-        foreach (array_keys($rgParent) as $x) {
-            $childSet =& $rgParent[$x];
-            foreach (array_keys($childSet) as $y) {
-                $mark =& $childSet[$y];
-                if (array_key_exists($mark['page_id'], $rgParent)) {
-                    $mark['sm2_has_child'] = true;
-                }
-                if ($mark['parent'] == $parentId && $mark['page_id'] != $CURR_PAGE_ID) {
-                    $mark['sm2_is_sibling'] = true;
-                }
-                unset($mark);
-            }
-            unset($childSet);
-        }
-
-        // mark all children of the current page. We don't do this when
-        // $CURR_PAGE_ID is 0, as 0 is the parent of everything.
-        // $CURR_PAGE_ID == 0 occurs on special pages like search results
-        // when no referrer is available.s
-        if ($CURR_PAGE_ID != 0) {
-            sm2_mark_children($rgParent, $CURR_PAGE_ID, 1);
-        }
-
-        // store the complete processed menu data as a global. We don't
-        // need to read this from the database anymore regardless of how
-        // many menus are displayed on the same page.
-        if (!array_key_exists('show_menu2_data', $GLOBALS)) {
-            $GLOBALS['show_menu2_data'] = array();
-        }
-        $GLOBALS['show_menu2_data'][$aMenu] =& $rgParent;
-        unset($rgParent);
-    }
-
-    // adjust $aMaxLevel to the level number of the final level that
-    // will be displayed. That is, we display all levels <= aMaxLevel.
-    if ($aMaxLevel == SM2::ALL) {
-        $aMaxLevel = 1000;
-    }
-    elseif ($aMaxLevel < 0) {   // SM2::CURR+N
-        $aMaxLevel += $pageLevel - SM2::CURR;
-    }
-    elseif ($aMaxLevel >= SM2::MAX) { // SM2::MAX+N
-        $aMaxLevel += $aStartLevel - SM2::MAX;
-        if ($aMaxLevel > $pageLevel) {
-            $aMaxLevel = $pageLevel;
-        }
-    }
-    else {  // SM2::START+N
-        $aMaxLevel += $aStartLevel - SM2::START;
-    }
-
-    // generate the menu
-    $retval = false;
-    if (array_key_exists($aStart, $GLOBALS['show_menu2_data'][$aMenu])) {
-        $formatter = $aItemOpen;
-        if (!is_object($aItemOpen)) {
-            static $sm2formatter;
-            if (!isset($sm2formatter)) {
-                $sm2formatter = new SM2_Formatter;
-            }
-            $formatter = $sm2formatter;
-            $formatter->set($flags, $aItemOpen, $aItemClose,
-                $aMenuOpen, $aMenuClose, $aTopItemOpen, $aTopMenuOpen);
-        }
-
-        // adjust the level until we show everything and ignore the SM2_TRIM flag.
-        // Usually this will be less than the start level to disable it.
-        $showAllLevel = $aStartLevel - 1;
-        if (isset($aOptions['notrim'])) {
-            $showAllLevel = $aStartLevel + $aOptions['notrim'];
-        }
-
-        // display the menu
-        $formatter->initialize();
-        sm2_recurse(
-            $GLOBALS['show_menu2_data'][$aMenu],
-            $aStart,    // parent id to start displaying sub-menus
-            $aStartLevel, $showAllLevel, $aMaxLevel, $flags,
-            $formatter);
-        $formatter->finalize();
-
-        // if we are returning something, get the data
-        if (($flags & SM2::BUFFER) != 0) {
-            $retval = $formatter->getOutput();
-        }
-    }
-
-    // clear the data if we aren't caching it
-    if (($flags & SM2::NOCACHE) != 0) {
-        unset($GLOBALS['show_menu2_data'][$aMenu]);
-    }
-    if(defined('DEBUG') && (DEBUG)) {
-        $iQueriesDone = $database->getQueryCount - $iQueryStart;
-        return $retval."\n".'<!-- Queries: '.$iQueriesDone.' -->'."\n";
-    }
-    return $retval;
-}
-
-function sm2_mark_children(&$rgParent, $aStart, $aChildLevel)
-{
-    if (array_key_exists($aStart, $rgParent)) {
-        foreach (array_keys($rgParent[$aStart]) as $y) {
-            $mark =& $rgParent[$aStart][$y];
-            $mark['sm2_child_level'] = $aChildLevel;
-            $mark['sm2_on_curr_path'] = true;
-            sm2_mark_children($rgParent, $mark['page_id'], $aChildLevel+1);
-        }
-    }
-}
-
-function sm2_recurse(
-    &$rgParent, $aStart,
-    $aStartLevel, $aShowAllLevel, $aMaxLevel, $aFlags,
-    &$aFormatter
-    )
-{
-    global $wb;
-
-    // on entry to this function we know that there are entries for this
-    // parent and all entries for that parent are being displayed. We also
-    // need to check if any of the children need to be displayed too.
-    $isListOpen = false;
-    $currentLevel = $wb->page['level'] == '' ? 0 : $wb->page['level'];
-
-    // get the number of siblings skipping the hidden pages so we can pass
-    // this in and check if the item is first or last
-    $sibCount = 0;
-    foreach ($rgParent[$aStart] as $page) {
-        if (!array_key_exists('sm2_hide', $page)) $sibCount++;
-    }
-
-    $currSib = 0;
-    foreach ($rgParent[$aStart] as $page) {
-        // skip all hidden pages
-        if (array_key_exists('sm2_hide', $page)) { // not set if false, so existence = true
-            continue;
-        }
-
-        $currSib++;
-
-        // skip any elements that are lower than the maximum level
-        $pageLevel = $page['level'];
-        if ($pageLevel > $aMaxLevel) {
-            continue;
-        }
-
-        // this affects ONLY the top level
-        if ($aStart == 0 && ($aFlags & SM2::CURRTREE)) {
-            if (!array_key_exists('sm2_on_curr_path', $page)) { // not set if false, so existence = true
-                continue;
-            }
-            $sibCount = 1;
-        }
-
-        // trim the tree as appropriate
-        if ($aFlags & SM2::SIBLING) {
-            // parents, and siblings and children of current only
-            if (!array_key_exists('sm2_on_curr_path', $page)      // not set if false, so existence = true
-                && !array_key_exists('sm2_is_sibling', $page)     // not set if false, so existence = true
-                && !array_key_exists('sm2_child_level', $page)) { // not set if false, so existence = true
-                continue;
-            }
-        }
-        else if ($aFlags & SM2::TRIM) {
-            // parents and siblings of parents
-            if ($pageLevel > $aShowAllLevel  // permit all levels to be shown
-                && !array_key_exists('sm2_on_curr_path', $page)    // not set if false, so existence = true
-                && !array_key_exists('sm2_path_sibling', $page)) {  // not set if false, so existence = true
-                continue;
-            }
-        }
-        elseif ($aFlags & SM2::CRUMB) {
-            // parents only
-            if (!array_key_exists('sm2_on_curr_path', $page)    // not set if false, so existence = true
-                || array_key_exists('sm2_child_level', $page)) {  // not set if false, so existence = true
-                continue;
-            }
-        }
-
-        // depth first traverse
-        $nextParent = $page['page_id'];
-
-        // display the current element if we have reached the start level
-        if ($pageLevel >= $aStartLevel) {
-            // massage the link into the correct form
-            if(!INTRO_PAGE && $page['link'] == $wb->default_link) {
-                $url = WB_URL.'/';
-            }
-            else {
-                $url = $wb->page_link($page['link']);
-            }
-
-            // we open the list only when we absolutely need to
-            if (!$isListOpen) {
-                $aFormatter->startList($page, $url);
-                $isListOpen = true;
-            }
-
-            $aFormatter->startItem($page, $url, $currSib, $sibCount);
-        }
-
-        // display children as appropriate
-        if ($pageLevel + 1 <= $aMaxLevel
-            && array_key_exists('sm2_has_child', $page)) {  // not set if false, so existence = true
-            sm2_recurse(
-                $rgParent, $nextParent, // parent id to start displaying sub-menus
-                $aStartLevel, $aShowAllLevel, $aMaxLevel, $aFlags,
-                $aFormatter);
-        }
-
-        // close the current element if appropriate
-        if ($pageLevel >= $aStartLevel) {
-            $aFormatter->finishItem($pageLevel, $page);
-        }
-    }
-
-    // close the list if we opened one
-    if ($isListOpen) {
-        $aFormatter->finishList();
-    }
-}
\ No newline at end of file

Property changes on: branches/2.8.x/wb/modules/show_menu2/include.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/index.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/index.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/index.php	(nonexistent)
@@ -1,21 +0,0 @@
-<?php
-/**
- *
- * @category        module
- * @package         show_menu2
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link			http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.7.0 | 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$ 
- * @filesource		$HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-header('Location: ../index.php');
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/index.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/LICENCE.txt
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/LICENCE.txt	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/LICENCE.txt	(nonexistent)
@@ -1,278 +0,0 @@
-		    GNU GENERAL PUBLIC LICENSE
-		       Version 2, June 1991
-
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.
-                       51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-			    Preamble
-
-  The licenses for most software are designed to take away your
-freedom to share and change it.  By contrast, the GNU General Public
-License is intended to guarantee your freedom to share and change free
-software--to make sure the software is free for all its users.  This
-General Public License applies to most of the Free Software
-Foundation's software and to any other program whose authors commit to
-using it.  (Some other Free Software Foundation software is covered by
-the GNU Library General Public License instead.)  You can apply it to
-your programs, too.
-
-  When we speak of free software, we are referring to freedom, not
-price.  Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
-
-  To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if you
-distribute copies of the software, or if you modify it.
-
-  For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must give the recipients all the rights that
-you have.  You must make sure that they, too, receive or can get the
-source code.  And you must show them these terms so they know their
-rights.
-
-  We protect your rights with two steps: (1) copyright the software, and
-(2) offer you this license which gives you legal permission to copy,
-distribute and/or modify the software.
-
-  Also, for each author's protection and ours, we want to make certain
-that everyone understands that there is no warranty for this free
-software.  If the software is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original, so
-that any problems introduced by others will not reflect on the original
-authors' reputations.
-
-  Finally, any free program is threatened constantly by software
-patents.  We wish to avoid the danger that redistributors of a free
-program will individually obtain patent licenses, in effect making the
-program proprietary.  To prevent this, we have made it clear that any
-patent must be licensed for everyone's free use or not licensed at all.
-
-  The precise terms and conditions for copying, distribution and
-modification follow.
-
-		    GNU GENERAL PUBLIC LICENSE
-   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
-  0. This License applies to any program or other work which contains
-a notice placed by the copyright holder saying it may be distributed
-under the terms of this General Public License.  The "Program", below,
-refers to any such program or work, and a "work based on the Program"
-means either the Program or any derivative work under copyright law:
-that is to say, a work containing the Program or a portion of it,
-either verbatim or with modifications and/or translated into another
-language.  (Hereinafter, translation is included without limitation in
-the term "modification".)  Each licensee is addressed as "you".
-
-Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope.  The act of
-running the Program is not restricted, and the output from the Program
-is covered only if its contents constitute a work based on the
-Program (independent of having been made by running the Program).
-Whether that is true depends on what the Program does.
-
-  1. You may copy and distribute verbatim copies of the Program's
-source code as you receive it, in any medium, provided that you
-conspicuously and appropriately publish on each copy an appropriate
-copyright notice and disclaimer of warranty; keep intact all the
-notices that refer to this License and to the absence of any warranty;
-and give any other recipients of the Program a copy of this License
-along with the Program.
-
-You may charge a fee for the physical act of transferring a copy, and
-you may at your option offer warranty protection in exchange for a fee.
-
-  2. You may modify your copy or copies of the Program or any portion
-of it, thus forming a work based on the Program, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
-    a) You must cause the modified files to carry prominent notices
-    stating that you changed the files and the date of any change.
-
-    b) You must cause any work that you distribute or publish, that in
-    whole or in part contains or is derived from the Program or any
-    part thereof, to be licensed as a whole at no charge to all third
-    parties under the terms of this License.
-
-    c) If the modified program normally reads commands interactively
-    when run, you must cause it, when started running for such
-    interactive use in the most ordinary way, to print or display an
-    announcement including an appropriate copyright notice and a
-    notice that there is no warranty (or else, saying that you provide
-    a warranty) and that users may redistribute the program under
-    these conditions, and telling the user how to view a copy of this
-    License.  (Exception: if the Program itself is interactive but
-    does not normally print such an announcement, your work based on
-    the Program is not required to print an announcement.)
-
-These requirements apply to the modified work as a whole.  If
-identifiable sections of that work are not derived from the Program,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works.  But when you
-distribute the same sections as part of a whole which is a work based
-on the Program, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Program.
-
-In addition, mere aggregation of another work not based on the Program
-with the Program (or with a work based on the Program) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
-  3. You may copy and distribute the Program (or a work based on it,
-under Section 2) in object code or executable form under the terms of
-Sections 1 and 2 above provided that you also do one of the following:
-
-    a) Accompany it with the complete corresponding machine-readable
-    source code, which must be distributed under the terms of Sections
-    1 and 2 above on a medium customarily used for software interchange; or,
-
-    b) Accompany it with a written offer, valid for at least three
-    years, to give any third party, for a charge no more than your
-    cost of physically performing source distribution, a complete
-    machine-readable copy of the corresponding source code, to be
-    distributed under the terms of Sections 1 and 2 above on a medium
-    customarily used for software interchange; or,
-
-    c) Accompany it with the information you received as to the offer
-    to distribute corresponding source code.  (This alternative is
-    allowed only for noncommercial distribution and only if you
-    received the program in object code or executable form with such
-    an offer, in accord with Subsection b above.)
-
-The source code for a work means the preferred form of the work for
-making modifications to it.  For an executable work, complete source
-code means all the source code for all modules it contains, plus any
-associated interface definition files, plus the scripts used to
-control compilation and installation of the executable.  However, as a
-special exception, the source code distributed need not include
-anything that is normally distributed (in either source or binary
-form) with the major components (compiler, kernel, and so on) of the
-operating system on which the executable runs, unless that component
-itself accompanies the executable.
-
-If distribution of executable or object code is made by offering
-access to copy from a designated place, then offering equivalent
-access to copy the source code from the same place counts as
-distribution of the source code, even though third parties are not
-compelled to copy the source along with the object code.
-
-  4. You may not copy, modify, sublicense, or distribute the Program
-except as expressly provided under this License.  Any attempt
-otherwise to copy, modify, sublicense or distribute the Program is
-void, and will automatically terminate your rights under this License.
-However, parties who have received copies, or rights, from you under
-this License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-  5. You are not required to accept this License, since you have not
-signed it.  However, nothing else grants you permission to modify or
-distribute the Program or its derivative works.  These actions are
-prohibited by law if you do not accept this License.  Therefore, by
-modifying or distributing the Program (or any work based on the
-Program), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Program or works based on it.
-
-  6. Each time you redistribute the Program (or any work based on the
-Program), the recipient automatically receives a license from the
-original licensor to copy, distribute or modify the Program subject to
-these terms and conditions.  You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
-this License.
-
-  7. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License.  If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Program at all.  For example, if a patent
-license would not permit royalty-free redistribution of the Program by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Program.
-
-If any portion of this section is held invalid or unenforceable under
-any particular circumstance, the balance of the section is intended to
-apply and the section as a whole is intended to apply in other
-circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system, which is
-implemented by public license practices.  Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-
-  8. If the distribution and/or use of the Program is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Program under this License
-may add an explicit geographical distribution limitation excluding
-those countries, so that distribution is permitted only in or among
-countries not thus excluded.  In such case, this License incorporates
-the limitation as if written in the body of this License.
-
-  9. The Free Software Foundation may publish revised and/or new versions
-of the General Public License from time to time.  Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
-Each version is given a distinguishing version number.  If the Program
-specifies a version number of this License which applies to it and "any
-later version", you have the option of following the terms and conditions
-either of that version or of any later version published by the Free
-Software Foundation.  If the Program does not specify a version number of
-this License, you may choose any version ever published by the Free Software
-Foundation.
-
-  10. If you wish to incorporate parts of the Program into other free
-programs whose distribution conditions are different, write to the author
-to ask for permission.  For software which is copyrighted by the Free
-Software Foundation, write to the Free Software Foundation; we sometimes
-make exceptions for this.  Our decision will be guided by the two goals
-of preserving the free status of all derivatives of our free software and
-of promoting the sharing and reuse of software generally.
-
-			    NO WARRANTY
-
-  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
-FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
-OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
-PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
-OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
-TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
-PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
-REPAIR OR CORRECTION.
-
-  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
-REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
-INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
-OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
-TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
-YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
-PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGES.

Property changes on: branches/2.8.x/wb/modules/show_menu2/LICENCE.txt
___________________________________________________________________
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/info.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/info.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/info.php	(nonexistent)
@@ -1,26 +0,0 @@
-<?php
-/**
- *
- * @category        module
- * @package         show_menu2
- * @author          Brodie Thiesfield
- * @author          WebsiteBaker Project
- * @copyright       2009-2013, WebsiteBaker Org. e.V.
- * @link            http://www.websitebaker.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.8.4
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- */
-
-$module_directory = 'show_menu2';
-$module_name = 'show_menu2';
-$module_function = 'snippet';
-$module_version = '4.9.7';
-$module_platform = '2.8.4';
-$module_author = 'Brodie Thiesfield';
-$module_license = 'GNU General Public License';
-$module_description = 'A code snippet for the Website Baker CMS providing a complete replacement for the builtin menu functions. See <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> for details or view the <a href="' .WB_URL .'/modules/show_menu2/README.en.txt" target="_blank">readme</a> file.';

Property changes on: branches/2.8.x/wb/modules/show_menu2/info.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/languages/DA.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/languages/DA.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/languages/DA.php	(nonexistent)
@@ -1,32 +0,0 @@
-<?php
-
-// $Id$
-
-/*
-    show_menu2: show_menu replacement for Website Baker 
-    Copyright (C) 2006-2009, Brodie Thiesfield
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
-    02110-1301, USA.
-
- -----------------------------------------------------------------------------------------
-  DANISH LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
- -----------------------------------------------------------------------------------------
-*/
-
-// Dansk modulbeskrivelse
-$module_description = 'Dette modul integrerer den udvidede men&uuml;funktion <code>show_menu2()</code> i Website Baker. Der findes detaljeret information p&aring; <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> eller i <a href="{WB_URL}/modules/show_menu2/README.en.txt" target="_blank">readme</a>filen.';
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/languages/DA.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/languages/DE.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/languages/DE.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/languages/DE.php	(nonexistent)
@@ -1,32 +0,0 @@
-<?php
-
-// $Id$
-
-/*
-    show_menu2: show_menu replacement for Website Baker 
-    Copyright (C) 2006-2009, Brodie Thiesfield
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
-    02110-1301, USA.
-
- -----------------------------------------------------------------------------------------
-  GERMAN LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
- -----------------------------------------------------------------------------------------
-*/
-
-// Deutsche Modulbeschreibung
-$module_description = 'Dieses Modul integriert die erweiterte Men&uuml;funktion <code>show_menu2()</code> in Website Baker. Detailierte Informationen gibt es auf <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> oder in der <a href="{WB_URL}/modules/show_menu2/README.de.txt" target="_blank">readme</a> Datei.';
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/languages/DE.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/languages/FR.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/languages/FR.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/languages/FR.php	(nonexistent)
@@ -1,32 +0,0 @@
-<?php
-
-// $Id$
-
-/*
-    show_menu2: show_menu replacement for Website Baker 
-    Copyright (C) 2006-2009, Brodie Thiesfield
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
-    02110-1301, USA.
-
- -----------------------------------------------------------------------------------------
-  FRENCH LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
- -----------------------------------------------------------------------------------------
-*/
-
-//Module Description
-$module_description = 'Ce module int&egrave;gre la fonction de menu avanc&eacute;e <code> show_menu2 () </ code> dans Website Baker. Une information d&eacute;taill&eacute;e est disponible sur <a href="http://code.jellycan.com/show_menu2/" target="_blank"> http://code.jellycan.com/show_menu2/ </a> ou dans le fichier <a href = "{WB_URL}/modules/show_menu2/README_DE" target = "_blank"> README </a>.';
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/languages/FR.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/languages/index.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/languages/index.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/languages/index.php	(nonexistent)
@@ -1,25 +0,0 @@
-<?php
-
-/*
-    show_menu2: show_menu replacement for Website Baker 
-    Copyright (C) 2006-2009, Brodie Thiesfield
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
-    02110-1301, USA.
-*/
-
-header('Location: ../index.php');
-
-?>
\ No newline at end of file

Property changes on: branches/2.8.x/wb/modules/show_menu2/languages/index.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/languages/NL.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/languages/NL.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/languages/NL.php	(nonexistent)
@@ -1,32 +0,0 @@
-<?php
-
-// $Id$
-
-/*
-    show_menu2: show_menu replacement for Website Baker 
-    Copyright (C) 2006-2009, Brodie Thiesfield
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
-    02110-1301, USA.
-
- -----------------------------------------------------------------------------------------
-  DUTCH LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
- -----------------------------------------------------------------------------------------
-*/
-
-//Module Description
-$module_description = 'Deze module integreert een de geavanceerde menu functie <code> show_menu2 () </ code> in Website Baker. Gedetailleerde informatie is beschikbaar op <a href="http://code.jellycan.com/show_menu2/" target="_blank"> http://code.jellycan.com/show_menu2/ </a> of in de <a href = "{WB_URL}/modules/show_menu2/README_EN" target = "_blank"> README </a>.';
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/languages/NL.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/show_menu2/languages/NO.php
===================================================================
--- branches/2.8.x/wb/modules/show_menu2/languages/NO.php	(revision 2113)
+++ branches/2.8.x/wb/modules/show_menu2/languages/NO.php	(nonexistent)
@@ -1,32 +0,0 @@
-<?php
-
-// $Id$
-
-/*
-    show_menu2: show_menu replacement for Website Baker 
-    Copyright (C) 2006-2009, Brodie Thiesfield
-
-    This program is free software; you can redistribute it and/or
-    modify it under the terms of the GNU General Public License
-    as published by the Free Software Foundation; either version 2
-    of the License, or (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
-    02110-1301, USA.
-
- -----------------------------------------------------------------------------------------
-  NORWEGIAN LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
- -----------------------------------------------------------------------------------------
-*/
-
-// Norwegian Moduledscripton
-$module_description = 'Dette er en kode snutt (snippet) beregnet p&aring; Website Baker CMS og er en fullgod erstatning for den innebygde meny modulen. For n&aelig;rmere beskrivelse se (Kun p&aring; Engelsk) <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> , for mer WB spesifikke detaljer se <a href="' .WB_URL .'/modules/show_menu2/README.en.txt" target="_blank">readme</a> filen.';
-
-?>

Property changes on: branches/2.8.x/wb/modules/show_menu2/languages/NO.php
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Deleted: svn:keywords
## -1,4 +0,0 ##
-Id
-Revision
-HeadURL
-Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/uninstall.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/uninstall.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/uninstall.php	(revision 2114)
@@ -0,0 +1,21 @@
+<?php
+/**
+ *
+ * @category        modules
+ * @package         show_menu2
+ * @author          Independend-Software-Team
+ * @author          WebsiteBaker Project
+ * @copyright       2004-2009, Ryan Djurovich
+ * @copyright       2009-2011, Website Baker Org. e.V.
+ * @link            http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource      $HeadURL$
+ * @lastmodified    $Date$
+ *
+ */
+
+// Must include code to stop this file being access directly
+if(defined('WB_PATH') == false) { exit("Cannot access this file directly"); }

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/uninstall.php
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/info.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/info.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/info.php	(revision 2114)
@@ -0,0 +1,16 @@
+<?php
+/**
+ * The new 'info.ini' is mandatory from 2.8.4 !!!
+ * This file 'info-php' is for backward compatibility only!!!!!
+ * From 2.8.4 new core methods will no longer use the old vars from info.php!
+ * It will be removed at least at 1th of June 2015 !!!!
+ */
+    if (!defined('SYSTEM_RUN')) die('illegal access!');
+    $aX = UpgradeHelper::convInfoIni2InfoPhp(__DIR__);
+    if ($aX) {
+        $sPrefix = array_shift($aX);
+        extract($aX, EXTR_PREFIX_ALL, $sPrefix);
+    } else {
+        throw new AppException('error on converting values from '.basename(__DIR__).'/info.ini');
+    }
+

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/info.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/DOC/LICENCE.txt
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/DOC/LICENCE.txt	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/DOC/LICENCE.txt	(revision 2114)
@@ -0,0 +1,278 @@
+		    GNU GENERAL PUBLIC LICENSE
+		       Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+                       51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+			    Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users.  This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it.  (Some other Free Software Foundation software is covered by
+the GNU Library General Public License instead.)  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have.  You must make sure that they, too, receive or can get the
+source code.  And you must show them these terms so they know their
+rights.
+
+  We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+  Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software.  If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary.  To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+		    GNU GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License.  The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language.  (Hereinafter, translation is included without limitation in
+the term "modification".)  Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+  1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+  2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+    a) You must cause the modified files to carry prominent notices
+    stating that you changed the files and the date of any change.
+
+    b) You must cause any work that you distribute or publish, that in
+    whole or in part contains or is derived from the Program or any
+    part thereof, to be licensed as a whole at no charge to all third
+    parties under the terms of this License.
+
+    c) If the modified program normally reads commands interactively
+    when run, you must cause it, when started running for such
+    interactive use in the most ordinary way, to print or display an
+    announcement including an appropriate copyright notice and a
+    notice that there is no warranty (or else, saying that you provide
+    a warranty) and that users may redistribute the program under
+    these conditions, and telling the user how to view a copy of this
+    License.  (Exception: if the Program itself is interactive but
+    does not normally print such an announcement, your work based on
+    the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole.  If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works.  But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+  3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+    a) Accompany it with the complete corresponding machine-readable
+    source code, which must be distributed under the terms of Sections
+    1 and 2 above on a medium customarily used for software interchange; or,
+
+    b) Accompany it with a written offer, valid for at least three
+    years, to give any third party, for a charge no more than your
+    cost of physically performing source distribution, a complete
+    machine-readable copy of the corresponding source code, to be
+    distributed under the terms of Sections 1 and 2 above on a medium
+    customarily used for software interchange; or,
+
+    c) Accompany it with the information you received as to the offer
+    to distribute corresponding source code.  (This alternative is
+    allowed only for noncommercial distribution and only if you
+    received the program in object code or executable form with such
+    an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it.  For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable.  However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+  4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License.  Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+  5. You are not required to accept this License, since you have not
+signed it.  However, nothing else grants you permission to modify or
+distribute the Program or its derivative works.  These actions are
+prohibited by law if you do not accept this License.  Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+  6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions.  You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+  7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License.  If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all.  For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices.  Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+  8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded.  In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+  9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time.  Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number.  If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation.  If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+  10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission.  For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this.  Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+			    NO WARRANTY
+
+  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/DOC/LICENCE.txt
___________________________________________________________________
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/DOC/README.de.txt
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/DOC/README.de.txt	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/DOC/README.de.txt	(revision 2114)
@@ -0,0 +1,667 @@
+﻿show_menu2, version 4.9
+=======================
+Ist ein Code-Snippet für das CMS Website Baker. Es stellt einen kompletten
+Ersatz für die eingebaute Menüfuntionalität zur Verfügung. Alle, für die
+Erzeugung des Menüs erforderlichen Daten, werden durch eine einzige
+Datenbankabfrage erzeugt. Durch umfangreiche Anpassungsmöglichkeiten des
+erzeugten HTML-Code können alle möglichen Menüarten (Listen, Breadcrumbs,
+Sitemaps, usw.) erzeugt werden.
+
+---
+Deutsche Übersetzung von BerndJM. Dies ist eine weitgehend direkte Übersetzung
+des englischen Originals. Bei Übersetzungs- oder Interpretationsfehlern, bitte
+eine Email an bjm@wwnw.de.
+---
+
+
+
+INSTALLATION
+============
+1. Die aktuelle Version von http://code.jellycan.com/show_menu2/ herunterladen.
+2. In das Admin-Backend der Website Baker Installation einlogen.
+3. Erweiterungen -> Module aufrufen.
+4. Wenn bereits eine frühere Version von show_menu2 installiert ist, diese über
+   "Modul deinstallieren" auswählen und deinstallieren.
+5. Im Abschnitt "Modul installieren" das im Schritt 1 heruntergeladene zip-File
+   auswählen und installieren.
+
+
+
+BENUTZUNG VON SHOW_MENU2
+========================
+Um show_menu2 zu benutzen muss das verwendete Template an den Stellen
+modifiziert werden, an denen das Menü erscheinen soll. Bitte beachten: Wenn alte
+Menüaufrufe ersetzt werden, müssen unbedingt auch die entsprechenden neuen
+Parameter verwendet werden die show_menu2 benötigt.
+
+In den meisten Fällen genügt bereits der Standardaufruf ohne weitere Parameter
+von show_menu2. In diesem Fall werden die Vorgabewerte verwendet, dies erzeugt
+ein Menü das die aktuelle Seite und die Unterseiten der aktuellen Seite anzeigt:
+
+    $sMenu = show_menu2();
+
+Bitte beachten: der Aufruf von show_menu2 ist PHP und muss normalerweise in PHP-
+Codezeichen eingeschlossen werden (ausser der Aufruf erfolgt bereits innerhalb
+von PHP Code):
+
+    <?php echo show_menu2(); ?>
+
+Dieses Vorgabe Menü erzeugt bereits ein komplettes Menü auf Listenbasis mit
+etlichen Klassen, die eine leichte Formatierung mittels CSS ermöglichen. Es wird
+z.B. die Klasse "menu-current" zu dem <li> tag des aktuellen Menüpunktes
+hinzugefügt. Zusätzlich erhält jeder Menüpunkt der Unterpunkte enthält die
+Klasse "menu-expand". Das erlaubt es sehr differenzierte CSS Regeln für die
+einzelnen Menüpunkte aufzustellen.
+Zum Beispiel:
+
+    li.menu-expand  { font-weight: bold; }
+    li.menu-current { background: red; }
+
+Im Abschnitt "HTML-Ausgabe" findet sich eine detaillierte Beschreibung welche
+Klassen welchem Element zugeordnet werden. Durch die Verwendung von
+verschiedenen Parametern bei dem show_menu2 Funktionsaufruf lassen sich auch
+recht umfangreiche und unterschiedliche Menüstrukturen erzeugen. Um
+beispielsweise nur Menüpunkte aus der obersten Ebene der Menüstruktur
+darzustellen, könnte man folgenden Aufruf verwenden:
+
+    $sMenu = show_menu2(0, SM2_ROOT, SM2_START);
+
+Oder um beispielsweise bis zu zwei Unterebenen der aktuellen Seite anzuzeigen:
+
+    $sMenu = show_menu2(0, SM2_CURR+1, SM2_CURR+2);
+
+Es gibt jede Menge Möglichkeiten, um die unterschiedlichsten Menüstrukturen zu
+erzeugen. Zahlreiche Beispiele dazu findet man auf der Demo-Website: http://
+code.jellycan.com/sm2test/
+
+
+
+HÄUFIGE FRAGEN
+==============
+
+Q:  Ich bin kein Programmierer. Gibt es keine einfachere Dokumentation?
+A:  Nein, denn dies hier ist bereits die einfache Dokumentation.
+
+
+Q:  Wie kann ich ein sogenanntes Drop-Down Menü erstellen?
+A:  Dies hat nichts mit show_menu2 zu tun. Um ein Drop-Down Menü zu erzeugen muß
+    lediglich der CSS-Code des jeweiligen Templates angepaßt werden. Die nötigen
+    Anpassungen findet man z.B. im "allcss2" Template aus dem WB Addon
+    Repository -> http://addons.websitebaker.org/
+
+
+Q:  Warum verschwindet das Menü nachdem ich in einer mehrsprachigen WB-Site die
+    Suchfunktion benutzt habe?
+A:  Im verwendeten Template fehlen die notwendigen Zeilen:
+
+    1.  Im WB Admin Backend: Optionen -> Erweiterte Optionen anzeigen ->
+        Suchoptionen -> Kopfzeile - hier direkt nach dem öffnenden <form> tag
+        folgende Zeile einfügen:
+
+        <input type="hidden" name="referrer" value="[REFERRER_ID]" />
+
+    2.  In der index.php des verwendeten Templates folgende Zeile unmittelbar
+        nach dem öffnenden <form> tag der Suche einfügen:
+
+        <input type="hidden" name="referrer" value="<?php echo defined('REFERRER_ID')?REFERRER_ID:PAGE_ID;?>" />
+
+
+Q:  Mehrsprachig? Das klingt toll. Wie macht man das?
+A:  http://www.websitebaker2.org/de/hilfe/designerhandbuch/mehrsprachige-webseiten.php
+
+
+Q:  Jedesmal wenn eine Seite aufgerufen wird, erzeugt SM2 folgende Warnmeldung:
+    "show_menu2 error: $aOptions is invalid. No flags from group 1 supplied!"
+A:  Der Funktion wurden die falschen Werte oder eine falsche Anzahl an
+    Werten übergeben.
+    Siehe den Abschnitt PARAMETER für die korrekten Flag Werte die dem
+    $aOptions Parameter zu übergeben sind.
+
+
+Q:  How do I use a different class/picture/color/widget for each entry in a menu?
+A:  Use the [page_id] format string in the $aItemOpen string. Create a unique
+    class or id for each menu item, then reference that item in your CSS or Javascript
+    to do whatever you want.
+
+    To add a unique class for each menu item (or similar):
+
+        "<li><a href="[url]" target="[target]" class="[class] p[page_id]">[menu_title]</a>"
+
+        ... creating menu items like ...
+
+        <li><a href="/pages/foo/bar.php" target="_top" class="menu-top p45">Top Menu</a>
+
+        Reference this in your CSS like:
+
+        a.p45 { color: red; }
+
+    To add a unique ID for each menu item (or similar):
+
+        "<li><a id="p[page_id]" href="[url]" target="[target]" class="[class]">[menu_title]</a>"
+
+        ... creating menu items like ...
+
+        <li><a id="p45" href="/pages/foo/bar.php" target="_top" class="menu-top">Top Menu</a>
+
+        Reference this in your CSS like:
+
+        a#p45 { color: red; }
+
+        Note that the ID can only be used if that menu is generated and displayed one time
+        only on the page (because HTML ID's must be unique within a page).
+
+
+FUNKTION
+========
+
+Der komplette Aufruf und die Vorgabe Parameterwerte für show_menu2 sind wie folgt:
+
+    show_menu2(
+        $aMenu          = 0,
+        $aStart         = SM2_ROOT,
+        $aMaxLevel      = SM2_CURR+1,
+        $aOptions       = SM2_TRIM,
+        $aItemOpen      = '[li][a][menu_title]</a>',
+        $aItemClose     = '</li>',
+        $aMenuOpen      = '[ul]',
+        $aMenuClose     = '</ul>',
+        $aTopItemOpen   = false,
+        $aTopMenuOpen   = false
+        )
+
+Im Abschnitt "Parameter" findet sich eine detaillierte Beschreibung jedes
+einzelnen Parameters.
+Jeder Parameter muß absolut korrekt verwendet werden. Folgende Regeln können
+dabei helfen:
+
+    $aMenu = 0 ist in den meisten Anwendungsfällen der beste Wert.
+
+    $aStart muß entweder eine page ID oder ein Wert der mit "SM2_" beginnt sein.
+
+    $aMaxLevel kann nur Werte erhalten, die mit "SM2_" beginnen.
+
+    $aOptions bis auf einige wenige Spezialfälle sind hier nur Werte die mit
+    "SM2_" beginnen zulässig.
+
+    Alle weiteren Parameter enthalten die (HTML)Tags die die Ausgabe des Menüs
+    steuern.
+
+    Ab $aItemOpen kann jedem Parameter der Wert false übergeben werden um den
+    jeweiligen Vorgabewert zu erhalten.
+
+    Dies kann beispielsweise verwendet werden um eine nummerierte Liste zu
+    erzeugen, während für die einzelnen Menüpunkte trotzdem die Vorgabewerte
+    Verwendung finden:
+
+        show_menu2(0, SM2_ROOT, SM2_ALL, SM2_ALL, false, false, '<ol>', '</ol>');
+
+Bitte beachten: bis einschliesslich $aOptions müssen alle Parameter explizit übergeben werden!
+
+
+HTML-AUSGABE
+============
+Die HTML-Ausgabe hängt wesentlich davon ab, welche Parameter an die Funktion übergeben werden.
+Unabhängig davon werden nachfolgende Klassen grundsätzlich für jedes Menü verwendet, wobei
+einzelne Menüpunkte, wenn es erforderlich ist, auch mehrere Klassen erhalten können.
+
+    KLASSE          ZUORDNUNG
+    ------------    -------------------------------------------------------
+    menu-top        Nur der erste Menüpunkt.
+    menu-parent     Jeder Hauptmenüpunkt.
+    menu-current    Nur der Menüpunkt der aktuellen Seite.
+    menu-sibling    Alle "Geschwister" der aktuellen Seite.
+    menu-child      Jedes Untermenü der aktuellen Seite.
+    menu-expand     Jedes Menü das Untermenüs hat.
+    menu-first      Der erste Punkt eines jeden Menüs oder Untermenüs.
+    menu-last       Der letzte Punkt eines jeden Menüs oder Untermenüs.
+
+    Folgende Klassen werden nur hinzugefügt, wenn das SM2_NUMCLASS Flag gesetzt
+    ist:
+
+    menu-N          Jeder Menüpunkt, wobei das N für die ABSOLUTE Menütiefe,
+                    beginnend bei 0, des jeweiligen Menüpunktes steht.
+                    Die oberste Ebene ist also immer menu-0, die nächste
+                    Ebene menu-1 usw.
+    menu-child-N    Jedes Untermenü der aktuellen Seiten, wobei das N für die
+                    RELATIVE Tiefe des Untermenüs, beginnend bei 0, steht.
+
+Beispiel einer HTML-Ausgabe:
+
+<ul class="menu-top menu-0">
+  <li class="menu-0 menu-first">  ... </li>
+  <li class="menu-0 menu-expand menu-parent">  ...
+  <ul class="menu-1">
+    <li class="menu-1 menu-expand menu-first">  ...
+    <ul class="menu-2">
+      <li class="menu-2 menu-first">  ...
+      <li class="menu-2 menu-last">  ...
+    </ul>
+    </li>
+    <li class="menu-1 menu-expand menu-parent">  ...
+    <ul class="menu-2">
+      <li class="menu-2 menu-expand menu-current menu-first">  ...      ** CURRENT PAGE **
+      <ul class="menu-3">
+        <li class="menu-3 menu-child menu-child-0 menu-first">  ...
+        <ul class="menu-4">
+          <li class="menu-4 menu-child menu-child-1 menu-first">  ... </li>
+          <li class="menu-4 menu-child menu-child-1 menu-last">  ... </li>
+        </ul>
+        </li>
+        <li class="menu-3 menu-child menu-child-0 menu-last">  ... </li>
+      </ul>
+      </li>
+      <li class="menu-2 menu-sibling menu-last">  ... </li>
+    </ul>
+    </li>
+    <li class="menu-1">  ... </li>
+    <li class="menu-1 menu-expand menu-last">  ...
+    <ul class="menu-2">
+      <li class="menu-2 menu-first menu-last">  ... </li>
+    </ul>
+    </li>
+  </ul>
+  </li>
+  <li class="menu-0 menu-last">  ... </li>
+</ul>
+
+
+PARAMETER
+=========
+$aMenu
+    Nummer des Menüs. Diese ist nützlich um mehrere Menüs auf einer Seite zu
+    verwenden.
+    Menü Nummer 0 ist das Vorgabemenü der aktuellen Seite, SM2_ALLMENU gibt alle
+    im System verwendeten Menüs zurück.
+
+$aStart
+    Gibt an, ab welcher Ebene die Erzeugung des Menüs beginnen soll. In den
+    meisten Fällen wird dies die oberste Ebene des anzuzeigenden Menüs sein. Es
+    kann einer der folgenden Werte verwendet werden:
+
+        SM2_ROOT+N  Beginnt N Ebenen unterhalb der obersten Ebene, z.B.:
+                    SM2_ROOT      Beginnt auf der obersten Ebene
+                    SM2_ROOT+1    Beginnt eine Ebene unterhalb der obersten Ebene
+                    SM2_ROOT+2    Beginnt zwei Ebenen unterhalb der obersten Ebene
+
+        SM2_CURR+N  Beginnt N Ebenen unterhalb der aktuellen Ebene, z.B.:
+                    SM2_CURR      Beginnt auf der aktuellen Ebene. Alle Geschwister
+                                  der aktuellen Ebene
+                    SM2_CURR+1    Beginnt eine Ebene unterhalb der aktuellen Ebene
+                                  mit allen Unterebenen
+
+        page_id     Verwendet die Seite mit der angegebenen page id als Elternelement.
+                    Alle Untermenüs dieser Seite werden angezeigt.
+                    (Die page id kann ermittelt werden, wenn man die Seite im
+                    Admin-Backend editiert, sie steht dann in der Adresszeile des
+                    Browsers: http://SITE/admin/pages/modify.php?page_id=35
+
+$aMaxLevel
+    Die maximale Anzahl der Ebenen die angezeigt werden. Die Anzeige
+    beginnt ab der in $aStart festgelegten Ebene, bis hin zu der hier
+    festgelegten Ebene.
+
+        SM2_ALL      Keine Beschränkung, alle Ebenen werden angezeigt
+
+        SM2_CURR+N   Zeigt immer die aktuelle Seite + N Ebenen.
+                     SM2_CURR      Aktuelle Ebene (keine Unterebene)
+                     SM2_CURR+3    Alle übergeordneten + aktuelle + 3 Unterebenen
+
+        SM2_START+N  Beginnt immer auf der Startebene + N Ebenen.
+                     Die Ebenen werden unabhängig davon angezeigt,egal
+                     auf welcher Ebene sich die aktuelle Seite befindet.
+                     SM2_START     Eine einzelne Ebene ab der Startebene.
+                     SM2_START+1   Startebene + eine Ebene darunter.
+
+        SM2_MAX+N    Zeigt höchstens N Ebenen ab der Startebene.
+                     Ebenen unterhalb der aktuellen Ebene werden nicht angezeigt.
+                     SM2_MAX       Nur die Startebene (gleiche Wirkung wie SM2_START)
+                     SM2_MAX+1     Die Startebene und eine Ebene darunter.
+
+$aOptions
+    Spezielle Flags für verschiedene Menügenerierungs Optionen. Sie können mittels
+    einer ODER Verknüpfung (|) miteinander kombiniert werden. Um beispielsweise
+    sowohl TRIM als auch PRETTY zu definieren, verwendet man: (SM2_TRIM | SM2_PRETTY).
+
+    GROUP 1
+    -------
+    Aus dieser Gruppe muss stets genau ein Flag angegeben werden. Diese Flags
+    bestimmen auf welche Weise die Geschwisterelemente im Menübaum in der
+    Ausgabe unterdrückt werden.
+
+    SM2_ALL         Zeigt alle Zweige des Menübaums
+                        A-1 -> B-1
+                            -> B-2 -> C-1
+                                   -> C-2 (CURRENT)
+                                          -> D-1
+                                          -> D-2
+                                   -> C-3
+                        A-2 -> B-3
+                            -> B-4
+
+    SM2_TRIM        Zeigt alle Geschwistermenüs der Seite im aktuellen Pfad.
+                    Alle Untermenüs von Elemnten die sich nicht im Pfad befinden
+                    werden entfernt.
+                        A-1 -> B-1
+                            -> B-2 -> C-1
+                                   -> C-2 (CURRENT)
+                                          -> D-1
+                                          -> D-2
+                                   -> C-3
+                        A-2
+
+    SM2_CRUMB       Zeigt den Breadcrumb Pfad des Menüs an, also den aktuellen
+                    Menüpunkt sowie alle Menüpunkte die dorthin führen.
+                        A-1 -> B-2 -> C-2 (CURRENT)
+
+    SM2_SIBLING     Wie SM2_TRIM, es werden aber nur Geschwistermenüs der aktuellen
+                    Seite angezeigt. Alle anderen Punkte werden unterdrückt.
+                        A-1 -> B-2 -> C-1
+                                   -> C-2 (CURRENT)
+                                          -> D-1
+                                          -> D-2
+                                   -> C-3
+
+    GROUP 2
+    -------
+    Diese Flags sind optional, sie können in beliebiger Anzahl kombiniert werden.
+
+    SM2_NUMCLASS    Fügt die nummerierten Menüklassen "menu-N" und
+                    "menu-child-N hinzu.
+
+    SM2_ALLINFO     Lädt alle Felder aus der Seitentabelle der Datenbank.
+                    Dies verursacht einen ziemlich hohen Speicherverbauch und sollte
+                    deshalb nur mit Bedacht verwendet werden.
+                    Dadurch werden z.B. die Keywords, die Seitenbeschreibung sowie
+                    all die anderen Informationen verfügbar, die normalerweise nicht
+                    geladen werden.
+                    Bitte beachten: dieses Flag muss beim ERSTEN Aufruf von schow_menu2
+                    für die jeweilige Menü ID verwendet werden, oder in Verbindung
+                    mit SM2_NOCACHE, sonst zeigt es keine Wirkung.
+
+    SM2_NOCACHE     Die aus der Datenbank gelesenen Daten werden bei erneutem Aufruf von
+                    show_menu2 nicht wiederverwendet sondern erneut aus der Datenbank
+                    gelesen.
+
+    SM2_PRETTY      Bringt die HTML-Ausgabe des Menüs mittels Leerzeichen und
+                    Zeilenumbrüchen in eine gut lesbare Form. Das ist besonders
+                    nützlich beim Debuggen der Menüausgabe.
+
+    SM2_NOBUFFER    Gibt den HTML-Code direkt aus und speichert ihn nicht zwischen.
+
+    SM2_CURRTREE    Schliesst alle anderen Toplevelmenüs von der Betrachtung aus.
+                    Es werden nur Menüpunkte des aktuellen Menüzweiges dargestellt.
+                    Dieses Flag kann bei Bedarf mit jedem Flag aus der Gruppe 1
+                    kombiniert werden.
+
+    SM2_ESCAPE      Wendet htmlspecialchars auf den Menüstring an.
+                    Dies kann bei älteren Websitebaker Installationen erforderlich
+                    sein um eine valide HTML Ausgabe zu erzeugen.
+
+    SM2_SHOWHIDDEN  Hidden pages are usually hidden all of the time, including
+                    when they are active (i.e. current page or a parent page).
+                    Use private pages for time when you want pages to be
+                    hidden except when active. However for compatibility with
+                    release 4.8, supply this flag to enable hidden pages to
+                    become visible when they are active.
+
+    SM2_XHTML_STRICT	Stellt die XHTML-Kompatibilität der Links sicher indem
+					in per [a] oder [ac] formatierten Links die Targetangabe
+					entfernt und das Argument title="[page_titel]" eingefügt
+					wird. Bei manuell zusammengestellten Links ist der Designer
+					selbst für die XHTML-Konformität zuständig.
+
+	SM2_NO_TITLE	Unterdrückt die Ausgabe des Inhaltes des Title-Attributes
+					bei [a] oder [ac] formatierten links. Im XHTML-Strikt Modus
+                    wird 'title' mit einen &nbsp; ausgegeben.
+
+    Für diesen Parameter gibt es auch einen erweiterten Modus, bei dem die Optionen
+    als assoziatives Array übergeben werden. Näheres dazu im Abschnitt ERWEITERTE
+    OPTIONEN. Für die meisten Anwendungsfälle wird dies jedoch NICHT benötigt.
+
+$aItemOpen
+    Dies legt den Formatstring fest, mit dem jeder einzelne Menüeintrag begonnen
+    wird. Für den allerersten Menüeintrag kann mittels $aTopItemOpen ein anderer
+    Formatstring definiert werden.
+    Wenn dieser Parameter auf false gesetzt wird, wird der Vorgabe Formatstring
+    '[li][a][menu_title]</a>' verwendet um die Kompatibilität zur Website Baker
+    Standardfunktion show_menu() zu gewährleisten.
+    Da die Formatierung mittels CSS-Klassen oftmals einfacher ist, wenn sie auf den
+    <a> tag angewendet werden, empfiehlt es sich hier folgenden Formatstring zu
+    verwenden: '<li>[ac][menu_title]</a>'.
+
+    Dieser Parameter kann auch als Instanz eine Formatierungklasse für das Menü
+    verwendet werden. Die nähere Beschreibung dazu findet sich im Abschnitt FORMATTER.
+    Wenn hier ein Formatter angegeben wird, werden alle Argumente
+    nach $aItemOpen ignoriert.
+
+$aItemClose
+    Dieser String schließt jeden Menüpunkt ab.
+    Bitte beachten: dies ist kein Formatstring und es werden keine Schlüsselworte
+    ersetzt!
+    Wenn dieser Parameter auf false gesetzt ist, wird die Vorgabe '</li>' verwendet.
+
+$aMenuOpen
+    Mit diesem Formatstring wird eine Liste von Menüeinträgen geöffnet. Für das erste
+    Menü kann mittels $aTopMenuOpen ein davon abweichender Formatstring definiert
+    werden.
+    Wenn dieser Parameter auf false gesetzt ist wird der Vorgabewert '[ul]'
+    verwendet.
+
+$aMenuClose
+    Dieser String schließt jedes Menü ab.
+    Bitte beachten: dies ist kein Formatstring und es werden keine Schlüsselworte
+    ersetzt!
+    Wenn dieser Parameter auf false gesetzt ist, wird die Vorgabe '</ul>' verwendet.
+
+$aTopItemOpen
+    Der Formatstring für den allerersten Menüpunkt. Wenn dieser Parameter auf false
+    gesetzt wird, wird der selbe Formatstring wie bei $aItemOpen verwendet.
+
+$aTopMenuOpen
+    Der Formatstring für das erste Menü. Wenn dieser Parameter auf false
+    gesetzt wird, wird der selbe Formatstring wie bei $aMenuOpen verwendet.
+
+
+
+ERWEITERTE OPTIONEN
+===================
+Der Parameter $aOptions kann auf zweierlei Arten verwendet werden. Zum einen, wie oben
+im Abschnitt PARAMETER beschrieben, diese Art sollte für die allermeisten
+Anwendungsfälle ausreichen. Um allerdings in speziellen Fällen die Sonderoptionen
+ansprechen zu können, müssen die erforderlichen Werte als assoziatives Array
+bereitgestellt werden.
+Bitte beachten: Die SM2_* Flags sind auch hierbei erforderlich und müßen als 'flags'
+übergeben werden.
+
+    'flags'     **ZWINGEND ERFORDELICH** Dies sind die Flags die oben im Abschnitt
+                PARAMETER unter $aOptions beschrieben wurden.
+
+    'notrim'    Hiermit wird eine Anzahl von Ebenen festegelegt, die relativ bezogen
+                auf die in $aStart festgelegte Menüebene, immer angezeigt werden. Dies
+                bewirkt, daß für diese Ebenen das SM2_TRIM Flag ignoriert wird.
+
+Um dieses Array zu verwenden, empfiehlt es sich es erst anzulegen und dann den
+$aOptions parameter mit dem angelegten Array zu beliefern:
+
+    $options = array('flags' => (SM2_TRIM|...), 'notrim' => 1);
+    $sMenu = show_menu2(0, SM2_ROOT, SM2_CURR+1, $options);
+
+
+
+FORMAT STRINGS
+==============
+Die folgenden Tags können in den Formatstrings für $aItemOpen und $aMenuOpen
+verwendet werden und sollen durch den entsprechenden Text ersetzt werden.
+
+[a]             <a> tag ohne Klasse:   '<a href="[url]" target="[target]">'
+[ac]            <a> tag mit Klasse:    '<a href="[url]" target="[target]" class="[class]">'
+[li]            <li> tag mit Klasse:   '<li class="[class]">'
+[ul]            <ul> tag mit Klasse:   '<ul class="[class]">'
+[class]         Liste der Klassen für diese Seite
+[menu_title]    Text des Menütitel
+                (HTML entity escaped ausser das SM2_NOESCAPE Flag ist gesetzt)
+[menu_icon_0]	die URL zu einer Bilddatei mit normal - Darstellung (ab WB2.8.4)
+[menu_icon_1]	die URL zu einer Bilddatei mit active/hover - Darstellung (ab WB2.8.4)
+[page_title]    text des Seitentitel
+                (HTML entity escaped ausser das SM2_NOESCAPE Flag ist gesetzt)
+[page_icon]		die URL zu einer seitenbezogenen Bilddatei (ab WB2.8.4)
+[tooltip]       Tooltip-Text, der normal im title-Attribut der Links ausgegeben wird (ab WB2.8.4)
+[url]           die URL der Seiten für den <a> tag
+[target]        das Seitenziel für den <a> tag
+[page_id]       die Page ID des aktuellen Menüpunktes.
+[parent]        die Page ID des übergeordneten Menüpunktes.
+[level]         die Seitenebene,
+                dies ist die gleiche Zahl die im "menu-N" CSS tag verwendet wird.
+[sib]           Anzahl der Geschwister des aktuellen Menüpunktes.
+[sibCount]      Anzahl aller Geschwister in diesem Menü.
+[if]            Bedingung (Details hierzu im Abschnitt "Bedingte Formatierung')
+
+Folgende tags sind NUR verfügbar, wenn das SM2_ALLINFO Flag gesetzt ist.
+
+[description]   Seitenbeschreibung
+[keywords]      Schlüsselworte der Seite
+
+
+
+BEDINGTE FORMATIERUNG
+=====================
+Die Anweisung für eine bedingte Formatierung kann eine der folgenden Formen haben:
+
+    [if(A){B}]
+    [if(A){B}else{C}]
+
+    A   Die Bedingung. Details dazu, siehe unten.
+
+    B   Der Ausdruck der verwendet wird, wenn die Bedingung erfüllt ist.
+        Dies kann ein beliebiger String sein, der jedoch nicht das Zeichen '}'
+        enthalten darf. Er kann jeden beliebigen Formatstring aus dem Abschnitt
+        'Format Strings' enthalten, jedoch keinen weiteren Bedingungstest (da das
+        Zeichen '}' nicht erlaubt ist).
+
+    C   Der Ausdruck der verwendet wird, wenn die Bedingung nicht erfüllt ist.
+        Dies kann ein beliebiger String sein, der jedoch nicht das Zeichen '}'
+        enthalten darf. Er kann jeden beliebigen Formatstring aus dem Abschnitt
+        'Format Strings' enthalten, jedoch keinen weiteren Bedingungstest (da das
+        Zeichen '}' nicht erlaubt ist).
+
+Die Bedingung ist eine Kombination von einem oder mehreren boolschen Vergleichen.
+Wenn mehr als ein Vergleich erforderlich ist, so muss dieser mit den anderen Vergleichen
+mittels || (boolsches oder - OR) oder && (boolsches und - AND) verknüpft werden.
+
+Ein einzelner Vergleich besteht aus dem linken Operanden, dem Operator und dem rechten
+Operanden.
+z.B. X == Y  - hierbei ist X der linke Operand, == der Operator und Y der rechte Operand.
+
+    Linker Operand. Muss eines der folgende Schlüsselworte sein:
+        class       Überprüfung ob diese Klasse existiert. Es sind nur die
+                    "==" and "!=" Operatoren erlaubt. In diesem Fall haben die Operatoren
+                    die Bedeutung von "enthält" bzw. "enthält nicht" an Stelle von
+                    "ist gleich" bzw. "ist nicht gleich"
+        level       Überprüfung der Seitenebene.
+        sib         Überprüfung der Geschwisteranzahl der aktuellen Seite.
+        sibCount    Überprüfung der Geamtanzahl der Geschwister im aktuellen Menü.
+        id          Überprüfung der page id.
+		target		Überprüfung der Target-Angabe
+
+    Operator. Muss einer der folgenden sein:
+        <           Kleiner als
+        <=          Kleiner oder gleich als
+        ==          Gleich
+        !=          Nicht gleich
+        >=          Grössr oder gleich als
+        >           Grösser als
+
+    Rechter Operand. Die Art dieses Operanden hängt von dem, für den linken Operanden
+                     verwendeten Schlüsselwort ab.
+        class       einer der "menu-*" Klassennamen wie sie im Abschnitt "Ausgabe"
+                    spezifiziert sind.
+        level       Überprüfung der Seitenebene gegen folgende Werte:
+                        <number>  die absolute Seitenebene
+                        root      die oberste Seitenebene
+                        granny    die Seitenebene über der übergeordneten Seitenebene
+                        parent    die übergeordnete Seitenebene
+                        current   die aktuelle Seitenebene
+                        child     die untergeornete Seitenebene
+        id          Überprüfung der page id gegen folgende Werte:
+                        <number>  die absolute page id
+                        parent    die übergeordnete page id
+                        current   die aktuelle page id
+        sib         Eine positive Integerzahl, oder "sibCount" um die Anzahl der
+                    Geschwister in diesem Menü zu überprüfen
+        sibCount    Eine positive Integerzahl
+		target		Ein String, der eine mögliche Targetangabe darstellt
+
+Folgende Beispiele ergeben "wahr" und der Ausdruck {exp} wird ausgeführt, wenn zutrifft:
+
+    [if(class==menu-expand){exp}]   hat ein Untermenü
+    [if(class==menu-first){exp}]    ist der erste Eintrag in einem Menü
+    [if(class!=menu-first){exp}]    ist NICHT der erste Eintrag in einem Menü
+    [if(class==menu-last){exp}]     ist der letzte Eintrag in einem Menü
+    [if(level==0){exp}]             befindet sich auf der obersten Ebene
+    [if(level>0){exp}]              befindet sich NICHT auf der obersten Ebene
+    [if(sib==2){exp}]               ist der zweite Eintrag in einem Menü
+    [if(sibCount>1){exp}]           ist in einem Menü mit mehr als einem Eintrag
+    [if(sibCount!=2){exp}]          ist in einem Menü, das nicht genau 2 Einträge hat
+    [if(level>parent){exp}]         ist in einem Geschwistermenü oder dem Untermenü eines
+                                    Geschwistermenüs
+    [if(id==parent){exp}]           ist der übergeordnete Punkt der aktuellen id
+	[if(target==_self){exp}]		im Target-Attribut ist der String '_self' enthalten
+
+Wenn eine sonst-Klausel (else) hinzugefügt wird, so wird diese in allen anderen Fällen
+ausgeführt.
+Zum Beispiel wird "foo" immer dann ausgeführt, wenn die if Überprüfung falsch ergibt, also:
+
+    [if(sib==2){exp}else{foo}]      ist NICHT der zweite Eintrag im Menü
+    [if(sibCount>2){exp}else{foo}]  ist NICHT in einem Menü mit mehr als zwei Einträgen
+
+Bei mehrfach Vergleichen wird der Ausdruck "exp" nur ausgeführt, wenn:
+
+    [if(sib == 1 || sib > 3){exp}]  ist der erste Eintrag ODER ist der vierte oder höhere
+    Eintrag im Menü
+
+    [if(id == current && class == menu-expand){exp}  ist der aktuelle Eintrag UND hat
+    Untermenüs
+
+Bitte beachten:
+Alle Überprüfungen werden in der Reihenfolge ausgeführt, in der sie notiert sind, denn:
+* es findet keine Überprüfung auf evtl. Schleifen statt (alle Überprüfungen werden immer ausgeführt)
+* Überprüfungen werden nicht gruppiert (eine Klammerung von Überprüfungen wird nicht unterstützt)
+* sowohl || als auch && haben die gleiche Wertigkeit
+
+
+
+FORMATTER
+=========
+Achtung: dies ist ein fortgeschrittenes und äusserst selten benötigtes Feature!
+
+Mit umfangreichen Kenntnissen in der PHP Programmierung ist es möglich den vordefinierten
+Formatierer von show_menu2 mit einem eigenen zu ersetzen.
+In der include.php von show_menu2 sieht man wie der Formatierer geschreiben werden muss.
+Die API, die verwendet werden muss, sieht wie folgt aus:
+
+(Anmerkung des Übersetzers: Kommentare sind nicht übersetzt, wer sich so weit vorwagt, sollte
+damit keine Probleme haben ;-)
+
+class SM2_Formatter
+{
+    // called once before any menu is processed to allow object initialization
+    function initialize() { }
+
+    // called to open the menu list
+    function startList($aPage, $aUrl) { }
+
+    // called to open the menu item
+    function startItem($aPage, $aUrl, $aCurrSib, $aSibCount) { }
+
+    // called to close the menu item
+    function finishItem() { }
+
+    // called to close the menu list
+    function finishList() { }
+
+    // called once after all menu has been processed to allow object finalization
+    function finalize() { }
+
+    // called once after finalize() if the SM2_NOOUTPUT flag is used
+    function getOutput() { }
+};

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/DOC/README.de.txt
___________________________________________________________________
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/DOC/README.en.txt
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/DOC/README.en.txt	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/DOC/README.en.txt	(revision 2114)
@@ -0,0 +1,607 @@
+show_menu2, version 4.9
+=======================
+A code snippet for the Website Baker CMS software. It provides a complete
+replacement for the builtin menu functions. All menu data is retrieved using
+a single database query, all types of menu styles (lists, breadcrums, sitemaps)
+can be generated with extensive customisation of the resulting HTML.
+
+
+
+INSTALLATION
+============
+1. Download the latest version from http://code.jellycan.com/show_menu2/
+2. Log into your WebsiteBaker installation
+3. Go to Addons -> Modules
+4. If a previous version of show_menu2 is already installed, select it from
+   the "Uninstall Module" list and choose the "Uninstall" button.
+5. In the "Install Module" section, enter the path to the show_menu2 zip file
+   that you downloaded in step 1, and choose the "Install" button.
+
+
+
+USING SHOW_MENU2
+================
+You need to modify the PHP files of your template to call show_menu2 where you
+wish to have the menu displayed. Remember when you replace calls to the old
+menu functions to use the new parameters that show_menu2 requires.
+
+Often times the default menu generated by show_menu2 is all that you need.
+This menu shows the current page and children of the current page. It is
+generated by just calling show_menu2 with no parameters. For example:
+
+    $sMenu = show_menu2();
+
+Note that the call to show_menu2 is PHP, so you usually need to wrap it in the
+PHP code brackets so that it will execute. Like this:
+
+    <?php echo show_menu2(); ?>
+
+This default menu generates a complete list based menu with many classes that
+allow easy CSS styling. For example, the current menu item will have the
+"menu-current" class added to the <li> tag. Additionally, every menu item with
+a sub-menu will have the "menu-expand" class added to the <li> tag. This allows
+you to create CSS rules to style those menu items differently. For example:
+
+    li.menu-expand  { font-weight: bold; }
+    li.menu-current { background: red; }
+
+See the "Output" section for details of exactly what classes are added to each
+element. More elaborate and different menu structures are able to be created by
+supplying different parameters to the show_menu2 function call. For example,
+to show only menu items from the top level of the menu you use:
+
+    $sMenu = show_menu2(0, SM2_ROOT, SM2_START);
+
+Alternatively, to show up to two levels of the child menus of the current page:
+
+    $sMenu = show_menu2(0, SM2_CURR+1, SM2_CURR+2);
+
+There are many more possible menus that can be generated by show_menu2. See the
+demonstration website at http://code.jellycan.com/sm2test/ for more examples.
+
+
+
+COMMON QUESTIONS
+================
+
+Q:  I'm not a programmer. Do you have simpler documentation?
+A:  Nup. This is it. Go hard. Gambarre.
+
+
+Q:  How do I create a drop-down menu?
+A:  This is unrelated to show_menu2. You need to change the template CSS code
+    to display the menu as a drop-down. Try the "allcss2" template from the WB
+    addon repository. http://addons.websitebaker.org/
+
+
+Q:  Why does the menu disappear after I do a search on my multilingual WB site?
+A:  You're missing some required lines in your template.
+
+    1.  Log into WB administration, and go to Settings -> Show advanced settings
+        -> Search Settings -> Header Code and add the following input field
+        after the <form> open tag:
+
+        <input type="hidden" name="referrer" value="[REFERRER_ID]" />
+
+
+    2.  In the index.php of your template, add the following input field
+        immediately following the search <form> open tag.
+
+        <input type="hidden" name="referrer" value="<?php echo defined('REFERRER_ID')?REFERRER_ID:PAGE_ID;?>" />
+
+
+Q:  Multilingual? That sounds cool. How do I do that?
+A:  http://www.websitebaker2.org/en/help/designer-guide/multilingual-websites.php
+
+
+Q:  SM2 is generating a warning every time the page is accessed:
+    "show_menu2 error: $aOptions is invalid. No flags from group 1 supplied!"
+A:  You are passing the wrong values to the function. Have a closer look at the
+    parameters that you are passing. See the PARAMETERS section below for the
+    correct flag values to pass for the $aOptions parameter.
+
+
+Q:  How do I use a different class/picture/color/widget for each entry in a menu?
+A:  Use the [page_id] format string in the $aItemOpen string. Create a unique
+    class or id for each menu item, then reference that item in your CSS or Javascript
+    to do whatever you want.
+
+    To add a unique class for each menu item (or similar):
+
+        "<li><a href="[url]" target="[target]" class="[class] p[page_id]">[menu_title]</a>"
+
+        ... creating menu items like ...
+
+        <li><a href="/pages/foo/bar.php" target="_top" class="menu-top p45">Top Menu</a>
+
+        Reference this in your CSS like:
+
+        a.p45 { color: red; }
+
+    To add a unique ID for each menu item (or similar):
+
+        "<li><a id="p[page_id]" href="[url]" target="[target]" class="[class]">[menu_title]</a>"
+
+        ... creating menu items like ...
+
+        <li><a id="p45" href="/pages/foo/bar.php" target="_top" class="menu-top">Top Menu</a>
+
+        Reference this in your CSS like:
+
+        a#p45 { color: red; }
+
+        Note that the ID can only be used if that menu is generated and displayed one time
+        only on the page (because HTML ID's must be unique within a page).
+
+
+
+FUNCTION
+========
+
+The complete call signature and default parameter value for show_menu2 is:
+
+    show_menu2(
+        $aMenu          = 0,
+        $aStart         = SM2_ROOT,
+        $aMaxLevel      = SM2_CURR+1,
+        $aOptions       = SM2_TRIM,
+        $aItemOpen      = '[li][a][menu_title]</a>',
+        $aItemClose     = '</li>',
+        $aMenuOpen      = '[ul]',
+        $aMenuClose     = '</ul>',
+        $aTopItemOpen   = false,
+        $aTopMenuOpen   = false
+        )
+
+See the "Parameters" section for detailed descriptions of each parameter.
+Ensure that you use each parameter correctly. Use the following rules:
+
+    $aMenu will be 0 for most people.
+
+    $aStart must be either a page ID or a value starting with "SM2_".
+
+    $aMaxLevel must be only values that start with "SM2_".
+
+    $aOptions must be only values that start with "SM2_" (unless you are
+    in a very small minority of users).
+
+    All other parameters are the HTML tag templates that will be
+    output for menus and menu items.
+
+Note that every parameter from $aItemOpen can be supplied as false to get
+the default value.
+
+
+
+HTML OUTPUT
+===========
+The menu is output differently depending on what parameters have been
+supplied to the function, however in general the following classes are used
+for each menu. Note that items will have multiple classes when relevant.
+
+    CLASS           ATTACHED TO
+    ------------    -------------------------------------------------------
+    menu-top        First menu tag only
+    menu-parent     Every parent menu item of the current page.
+    menu-current    Only the menu item for the current page.
+    menu-sibling    Every sibling of the current page.
+    menu-child      Every sub-menu of the current page.
+    menu-expand     Every menu item with children.
+    menu-first      First item in any menu or sub-menu.
+    menu-last       Last item in any menu or sub-menu.
+
+    The following classes are added only if SM2_NUMCLASS flag has been used.
+
+    menu-N          Every menu item. The N is replaced with the ABSOLUTE
+                    menu depth of the item starting with 0. The root level
+                    menu is always menu-0, the next level is menu-1, etc.
+    menu-child-N    Every sub-menu of the current page, the N is replaced
+                    with the relative depth of the submenu starting at 0.
+
+
+<ul class="menu-top menu-0">
+  <li class="menu-0 menu-first">  ... </li>
+  <li class="menu-0 menu-expand menu-parent">  ...
+  <ul class="menu-1">
+    <li class="menu-1 menu-expand menu-first">  ...
+    <ul class="menu-2">
+      <li class="menu-2 menu-first">  ...
+      <li class="menu-2 menu-last">  ...
+    </ul>
+    </li>
+    <li class="menu-1 menu-expand menu-parent">  ...
+    <ul class="menu-2">
+      <li class="menu-2 menu-expand menu-current menu-first">  ...      ** CURRENT PAGE **
+      <ul class="menu-3">
+        <li class="menu-3 menu-child menu-child-0 menu-first">  ...
+        <ul class="menu-4">
+          <li class="menu-4 menu-child menu-child-1 menu-first">  ... </li>
+          <li class="menu-4 menu-child menu-child-1 menu-last">  ... </li>
+        </ul>
+        </li>
+        <li class="menu-3 menu-child menu-child-0 menu-last">  ... </li>
+      </ul>
+      </li>
+      <li class="menu-2 menu-sibling menu-last">  ... </li>
+    </ul>
+    </li>
+    <li class="menu-1">  ... </li>
+    <li class="menu-1 menu-expand menu-last">  ...
+    <ul class="menu-2">
+      <li class="menu-2 menu-first menu-last">  ... </li>
+    </ul>
+    </li>
+  </ul>
+  </li>
+  <li class="menu-0 menu-last">  ... </li>
+</ul>
+
+
+
+PARAMETERS
+==========
+$aMenu
+    Menu number to use. This is useful when you are using multiple menus.
+    Supplying a menu number of 0 will use the default menu for the current
+    page. Supplying SM2_ALLMENU will return all menus in the system.
+
+$aStart
+    Specify where the menu generation should start from. This is most
+    times the parent item of the menu to display. It must be one of the
+    following values:
+        SM2_ROOT+N  Start N levels down from the root. e.g.
+                      SM2_ROOT      Starting at the root menu
+                      SM2_ROOT+1    Start 1 level below the root
+                      SM2_ROOT+2    Start 2 levels below the root
+        SM2_CURR+N  Start N levels down from the current page level. e.g.
+                      SM2_CURR      Starts at the current page level. All
+                                    sibling menus to the current page.
+                      SM2_CURR+1    Starts 1 level down from the current
+                                    page with the children menus.
+        page_id     Display using the specific page as the parent. All
+                    child menus of that page will be displayed. The
+                    page_id can be found by editing the page in WB admin
+                    interface. The page_id is included in the URL like:
+                        http://SITE/admin/pages/modify.php?page_id=35
+
+$aMaxLevel
+    Maximum menu level to display. Menus are displayed from the start
+    level down to this level.
+        SM2_ALL     No limit, all levels are displayed
+        SM2_CURR+N  Always show to the current page + N levels.
+                      SM2_CURR      Current (no children)
+                      SM2_CURR+3    All parents + current + 3 children
+        SM2_START+N Always show from the starting level + N levels. The
+                    levels of menu will always be displayed regardless of
+                    what level the current page is.
+                      SM2_START     Single level of menus from starting level
+                      SM2_START+1   Starting level and 1 level down
+        SM2_MAX+N   Show at most N levels from the starting level. Levels
+                    won't be shown if they are below the current level.
+                      SM2_MAX       Starting level only (same as SM2_START)
+                      SM2_MAX+1     Maximum of starting level and 1 level.
+
+$aOptions
+    Specify flags for different generation options for the menu. The flags
+    may be combined together using bitwise OR (|). For example, to specify
+    both TRIM and PRETTY you should use, (SM2_TRIM | SM2_PRETTY).
+
+    GROUP 1
+    -------
+    Exactly one flag from this group must always be supplied. These flags
+    affect how the siblings in the tree are removed from the output.
+
+    SM2_ALL         Show all branches of the menu tree
+                        A-1 -> B-1
+                            -> B-2 -> C-1
+                                   -> C-2 (CURRENT)
+                                          -> D-1
+                                          -> D-2
+                                   -> C-3
+                        A-2 -> B-3
+                            -> B-4
+    SM2_TRIM        Show all sibling menus of pages on the current path.
+                    All sub-menus of elements that are not on the path
+                    are removed.
+                        A-1 -> B-1
+                            -> B-2 -> C-1
+                                   -> C-2 (CURRENT)
+                                          -> D-1
+                                          -> D-2
+                                   -> C-3
+                        A-2
+    SM2_CRUMB       Show only the breadcrumb trail, i.e. the current
+                    menu and all of it's ancestor menus.
+                        A-1 -> B-2 -> C-2 (CURRENT)
+    SM2_SIBLING     The same as SM2_TRIM however only sibling menus of
+                    the current page are displayed. All other menus are
+                    trimmed to show only the path.
+                        A-1 -> B-2 -> C-1
+                                   -> C-2 (CURRENT)
+                                          -> D-1
+                                          -> D-2
+                                   -> C-3
+
+    GROUP 2
+    -------
+    All of these flags are optional. Any number of them may be combined.
+
+    SM2_NUMCLASS    Add the numbered menu classes to the menu. If this
+                    flag is supplied, the "menu-N" and "menu-child-N"
+                    classes will be added.
+
+    SM2_ALLINFO     Load all fields from the page table of the database.
+                    This will result in quite a lot of memory being used
+                    and is not recommended, however it will make keywords,
+                    descriptions, and other fields available. This data
+                    is not loaded by default.
+                    NOTE: This flag must be used on the *FIRST* call to
+                    show_menu2 *for this menu ID*, or in combination with
+                    SM2_NOCACHE otherwise it will have no effect.
+
+    SM2_NOCACHE     Do not reuse or store the data read from the database
+                    between calls to show_menu2.
+
+    SM2_PRETTY      Pretty print the menu HTML with spacing and newlines
+                    for debugging purposes.
+
+    SM2_BUFFER      Do not output the menu HTML but instead buffer it
+                    internally and return it as a string from show_menu2.
+
+    SM2_CURRTREE    Exclude all other top level menus from being considered.
+                    Only items in the current menu tree will be output.
+                    This can be combined with any of the Group 1 flags as
+                    necessary.
+
+    SM2_ESCAPE      Call htmlspecialchars on the menu strings. This may be
+                    required with older installations of WB. By escaping the
+                    raw database strings, it permits menus to have HTML
+                    formatting in them that would cause otherwise cause
+                    pages to fail validation.
+
+    SM2_SHOWHIDDEN  Hidden pages are usually hidden all of the time, including
+                    when they are active (i.e. current page or a parent page).
+                    Use private pages for time when you want pages to be
+                    hidden except when active. However for compatibility with
+                    release 4.8, supply this flag to enable hidden pages to
+                    become visible when they are active.
+
+    SM2_XHTML_STRICT	From all links, created by [a] or [ac], the 'target' -
+					attribute will be removed to preserve the XHTML-Compatibility
+
+	SM2_NO_TITLE	Supress the value of the 'title'-attributes on links which
+					are created by [a] or [ac] formatted links.
+
+    This parameter also has an extended mode where an associative array of
+    options is supplied. See the EXTENDED OPTIONS section for details.
+    Most users will NOT need to use this.
+
+$aItemOpen
+    Format string to use for creating each individual menu item entry.
+    A different format string may be used for the very first entry by
+    supplying a different format string for $aTopItemOpen. When set to
+    false, it uses the default of '[li][a][menu_title]</a>' to maintain
+    compatibility with show_menu(). Note however that CSS formatting is
+    often easier if the classes are added to the <a> tag. Use the format
+    string of '<li>[ac][menu_title]</a>' for this style of tag.
+
+    This parameter may also be specified as an instance of a formatting
+    class for the menu. See the section "Formatter" below for details of
+    the API this class must expose. When a formatter is supplied, all
+    arguments after $aItemOpen are ignored.
+
+$aItemClose
+    String used to close each item. Note that this is not a format
+    string and no keywords will be replaced. When set to false, it uses
+    the default of '</li>'.
+
+$aMenuOpen
+    Format string to use for opening a list of menu item entries. A
+    different format string may be used for the very first menu by
+    supplying a different format string for $aTopMenuOpen. When set to
+    false, it uses the default of '[ul]'.
+
+$aMenuClose
+    String used to close each menu. Note that this is not a format
+    string and no keywords will be replaced. When set to false, it uses
+    the default of '</ul>'.
+
+$aTopItemOpen
+    Format string for the first item. When set to false, it uses the same
+    format as $aItemOpen.
+
+$aTopMenuOpen
+    Format string for the first menu. When set to false, it uses the same
+    format as $aMenuOpen.
+
+
+
+EXTENDED OPTIONS
+================
+The $aOptions parameter is a dual mode parameter. For most users, only the
+SM2_* flags will be sufficient. However, to access the extra options, it
+must be supplied as an associative array. Note that the SM2_* flags are
+still required and must be supplied as 'flags'.
+
+    'flags'     **REQUIRED** These are the flags described in PARAMETERS
+                above for the $aOptions parameter.
+
+    'notrim'    Specify a number of levels relative to the menu level of
+                $aStart that will always be displayed. This will cause the
+                SM2_TRIM flag to be ignored for these levels.
+
+To supply one of these options in addition to the flags, the option array
+should be created and passed as the $aOptions parameter:
+
+    $options = array('flags' => (SM2_TRIM|...), 'notrim' => 1);
+    $sMenu = show_menu2(0, SM2_ROOT, SM2_CURR+1, $options);
+
+
+
+FORMAT STRINGS
+==============
+The following tags may be included in the format strings for $aItemOpen and
+$aMenuOpen and will be replaced with the appropriate text.
+
+[a]             <a> tag (no class):         '<a href="[url]" target="[target]">'
+[ac]            <a> tag including class:    '<a href="[url]" target="[target]" class="[class]">'
+[li]            <li> tag including class:   '<li class="[class]">'
+[ul]            <ul> tag including class:   '<ul class="[class]">'
+[class]         List of classes for that page
+[menu_title]    Menu title text (HTML entity escaped unless SM2_NOESCAPE flag is used)
+[menu_icon_0]	URL poining to an image for display normal - status (from WB2.8.4)
+[menu_icon_1]	URL poining to an image for display active/hover - status (from WB2.8.4)
+[page_title]    Page title text (HTML entity escaped unless SM2_NOESCAPE flag is used)
+[page_icon]		URL poining to an image relating to the current page (from WB2.8.4)
+[tooltip]       Tooltip caption, normaly shown in title-attribute of links (ab WB2.8.4)
+[url]           Page URL for the <a> tag
+[target]        Page target for the <a> tag
+[page_id]       Page ID of the current menu item
+[parent]        Page ID of the parent menu item
+[level]         Page level, the same number as is used for the "menu-N" CSS tag.
+[sib]           Current menu sibling number
+[sibCount]      Total number of siblings in this menu
+[if]            Conditional test (see section CONDITIONAL FORMATTING)
+
+The following tags are only available when the SM2_ALLINFO flag is used.
+
+[description]   Page description
+[keywords]      Page keywords
+
+
+
+CONDITIONAL FORMATTING
+======================
+The conditional formatting directive takes one of the following forms:
+
+    [if(A){B}]
+    [if(A){B}else{C}]
+
+    A   Conditional test. See below for more details.
+
+    B   Expression emitted when the if-test is true. This may be any string
+        that does NOT include the '}' character. It may include any of the
+        format strings described in the section FORMAT STRINGS with the
+        exception of the conditional test (because '}' is not permitted).
+
+    C   Expression emitted when the if-test is false. This may be any string
+        that does NOT include the '}' character. It may include any of the
+        format strings described in the section FORMAT STRINGS with the
+        exception of the conditional test (because '}' is not permitted).
+
+The conditional test is a combination of one or more boolean tests.
+If more than one test is supplied, it must be combined with other tests
+using either || (boolean OR) or && (boolean AND).
+
+A single test is made up of the left operand, operator and right operand.
+e.g. X == Y where X is the left operand, == is the operator and Y is the
+right operand.
+
+    Left operand. It must be one of the following keywords:
+        class       Test for existence of one of the classes. Only the
+                    "==" and "!=" operators are permitted. In this case
+                    these operators have the meaning of "includes"
+                    instead of "equals".
+        level       Test against the page level.
+        sib         Test against the current page sibling number.
+        sibCount    Test against the number of siblings in the menu.
+        id          Test against the page id.
+		target		Test against the target attribute
+
+    Operator. It must be one of the following:
+        <           Less Than
+        <=          Less Than Equals
+        ==          Equals
+        !=          Not Equal
+        >=          Greater Than Equals
+        >           Greater Than
+
+    Right operand. The type of this operand depends on the keyword used
+    for the left operand:
+        class       One of the "menu-*" class names as listed in the
+                    section "OUTPUT".
+        level       Test the page level against the following values:
+                      <number>  absolute page level
+                      root      the root page level
+                      granny    the grand-parent page level
+                      parent    the parent page level
+                      current   the current page level
+                      child     the child page level
+        id          Test the page id against the following values:
+                      <number>  absolute page id
+                      parent    the parent page id
+                      current   the current page id
+        sib         A positive integer, or "sibCount" to test against
+                    the count of siblings in this menu.
+        sibCount    A positive integer.
+		target		A string, containing a possible target
+
+For example, valid tests are expression "exp" is emitted only when the menu item:
+
+    [if(class==menu-expand){exp}]   has a sub-menu
+    [if(class==menu-first){exp}]    is first item in a menu
+    [if(class!=menu-first){exp}]    is NOT first item in a menu
+    [if(class==menu-last){exp}]     is last item in a menu
+    [if(level==0){exp}]             is at the root
+    [if(level>0){exp}]              is not at the root
+    [if(sib==2){exp}]               is the second item in a menu
+    [if(sibCount>1){exp}]           is in a menu with more than 1 entry
+    [if(sibCount!=2){exp}]          is in a menu which doesn't have exactly
+    [if(level>parent){exp}]         is in a sibling menu or child of a sibling
+    [if(id==parent){exp}]           is the parent of the current page
+	[if(target==_self){exp}]		if value of target-attribute is '_self'
+
+If an else-clause was added, then the expression for the else would be
+emitted in all other cases. For example the expression "foo" is emitted
+whenever the if-test is false, so therefore:
+
+    [if(sib==2){exp}else{foo}]          is NOT the second item in a menu
+    [if(sibCount>2){exp}else{foo}]      is NOT in a menu with more than 2 entries
+
+For multiple tests, the expression "exp" is emitted only when the menu item:
+
+    [if(sib == 1 || sib > 3){exp}]
+        [is the first item] OR [is the 4th or larger item] in the menu
+
+    [if(id == current && class == menu-expand){exp}
+        [is the current item] AND [it has children]
+
+Note that all tests are evaluated in the order listed because:
+ * there is no short-circuit evaluation (all individual tests are always evaluated)
+ * there is no grouping of tests (i.e. no support for parenthesis)
+ * both || and && are considered the same level
+
+
+
+FORMATTER
+=========
+Note: This is an advanced and rarely needed feature!
+
+If you are capable of extensive PHP programming, it is possible to replace the
+predefined menu formatter that show_menu2 is uses with a custom module. See the
+include.php file of show_menu2 for an example of how the menu formatter must be
+written. The API it must use is:
+
+class SM2_Formatter
+{
+    // called once before any menu is processed to allow object initialization
+    function initialize() { }
+
+    // called to open the menu list
+    function startList($aPage, $aUrl) { }
+
+    // called to open the menu item
+    function startItem($aPage, $aUrl, $aCurrSib, $aSibCount) { }
+
+    // called to close the menu item
+    function finishItem() { }
+
+    // called to close the menu list
+    function finishList() { }
+
+    // called once after all menu has been processed to allow object finalization
+    function finalize() { }
+
+    // called once after finalize() if the SM2_NOOUTPUT flag is used
+    function getOutput() { }
+};

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/DOC/README.en.txt
___________________________________________________________________
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/languages/NL.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/languages/NL.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/languages/NL.php	(revision 2114)
@@ -0,0 +1,32 @@
+<?php
+
+// $Id$
+
+/*
+    show_menu2: show_menu replacement for Website Baker 
+    Copyright (C) 2006-2009, Brodie Thiesfield
+
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU General Public License
+    as published by the Free Software Foundation; either version 2
+    of the License, or (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+    02110-1301, USA.
+
+ -----------------------------------------------------------------------------------------
+  DUTCH LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
+ -----------------------------------------------------------------------------------------
+*/
+
+//Module Description
+$module_description = 'Deze module integreert een de geavanceerde menu functie <code> show_menu2 () </ code> in Website Baker. Gedetailleerde informatie is beschikbaar op <a href="http://code.jellycan.com/show_menu2/" target="_blank"> http://code.jellycan.com/show_menu2/ </a> of in de <a href = "{WB_URL}/modules/show_menu2/README_EN" target = "_blank"> README </a>.';
+
+?>

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/languages/NL.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/languages/NO.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/languages/NO.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/languages/NO.php	(revision 2114)
@@ -0,0 +1,32 @@
+<?php
+
+// $Id$
+
+/*
+    show_menu2: show_menu replacement for Website Baker 
+    Copyright (C) 2006-2009, Brodie Thiesfield
+
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU General Public License
+    as published by the Free Software Foundation; either version 2
+    of the License, or (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+    02110-1301, USA.
+
+ -----------------------------------------------------------------------------------------
+  NORWEGIAN LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
+ -----------------------------------------------------------------------------------------
+*/
+
+// Norwegian Moduledscripton
+$module_description = 'Dette er en kode snutt (snippet) beregnet p&aring; Website Baker CMS og er en fullgod erstatning for den innebygde meny modulen. For n&aelig;rmere beskrivelse se (Kun p&aring; Engelsk) <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> , for mer WB spesifikke detaljer se <a href="' .WB_URL .'/modules/show_menu2/README.en.txt" target="_blank">readme</a> filen.';
+
+?>

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/languages/NO.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/languages/DA.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/languages/DA.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/languages/DA.php	(revision 2114)
@@ -0,0 +1,32 @@
+<?php
+
+// $Id$
+
+/*
+    show_menu2: show_menu replacement for Website Baker 
+    Copyright (C) 2006-2009, Brodie Thiesfield
+
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU General Public License
+    as published by the Free Software Foundation; either version 2
+    of the License, or (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+    02110-1301, USA.
+
+ -----------------------------------------------------------------------------------------
+  DANISH LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
+ -----------------------------------------------------------------------------------------
+*/
+
+// Dansk modulbeskrivelse
+$module_description = 'Dette modul integrerer den udvidede men&uuml;funktion <code>show_menu2()</code> i Website Baker. Der findes detaljeret information p&aring; <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> eller i <a href="{WB_URL}/modules/show_menu2/README.en.txt" target="_blank">readme</a>filen.';
+
+?>

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/languages/DA.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/languages/FR.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/languages/FR.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/languages/FR.php	(revision 2114)
@@ -0,0 +1,32 @@
+<?php
+
+// $Id$
+
+/*
+    show_menu2: show_menu replacement for Website Baker 
+    Copyright (C) 2006-2009, Brodie Thiesfield
+
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU General Public License
+    as published by the Free Software Foundation; either version 2
+    of the License, or (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+    02110-1301, USA.
+
+ -----------------------------------------------------------------------------------------
+  FRENCH LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
+ -----------------------------------------------------------------------------------------
+*/
+
+//Module Description
+$module_description = 'Ce module int&egrave;gre la fonction de menu avanc&eacute;e <code> show_menu2 () </ code> dans Website Baker. Une information d&eacute;taill&eacute;e est disponible sur <a href="http://code.jellycan.com/show_menu2/" target="_blank"> http://code.jellycan.com/show_menu2/ </a> ou dans le fichier <a href = "{WB_URL}/modules/show_menu2/README_DE" target = "_blank"> README </a>.';
+
+?>

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/languages/FR.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/languages/index.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/languages/index.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/languages/index.php	(revision 2114)
@@ -0,0 +1,25 @@
+<?php
+
+/*
+    show_menu2: show_menu replacement for Website Baker 
+    Copyright (C) 2006-2009, Brodie Thiesfield
+
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU General Public License
+    as published by the Free Software Foundation; either version 2
+    of the License, or (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+    02110-1301, USA.
+*/
+
+header('Location: ../index.php');
+
+?>
\ No newline at end of file

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/languages/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/languages/DE.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/languages/DE.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/languages/DE.php	(revision 2114)
@@ -0,0 +1,32 @@
+<?php
+
+// $Id$
+
+/*
+    show_menu2: show_menu replacement for Website Baker 
+    Copyright (C) 2006-2009, Brodie Thiesfield
+
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU General Public License
+    as published by the Free Software Foundation; either version 2
+    of the License, or (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+    02110-1301, USA.
+
+ -----------------------------------------------------------------------------------------
+  GERMAN LANGUAGE FILE FOR THE ADDON: SHOW_MENU2
+ -----------------------------------------------------------------------------------------
+*/
+
+// Deutsche Modulbeschreibung
+$module_description = 'Dieses Modul integriert die erweiterte Men&uuml;funktion <code>show_menu2()</code> in Website Baker. Detailierte Informationen gibt es auf <a href="http://code.jellycan.com/show_menu2/" target="_blank">http://code.jellycan.com/show_menu2/</a> oder in der <a href="{WB_URL}/modules/show_menu2/README.de.txt" target="_blank">readme</a> Datei.';
+
+?>

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/languages/DE.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/include.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/include.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/include.php	(revision 2114)
@@ -0,0 +1,860 @@
+<?php
+/**
+ *
+ * @category        module
+ * @package         show_menu2
+ * @author          WebsiteBaker Project
+ * @copyright       Brodie Thiesfield
+ * @copyright       2009-2013, WebsiteBaker Org. e.V.
+ * @link            http://www.websitebaker.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.7.0 | 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource      $HeadURL$
+ * @lastmodified    $Date$
+ *
+ */
+
+// Must include code to stop this file being access directly
+if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
+
+/**
+ * future replacement for the function show_menu2()
+ */
+class SM2
+{
+    const ROOT =          -1000;
+    const CURR =          -2000;
+    const ALLMENU =          -1;
+    const START =          1000;
+    const MAX =            2000;
+    const ALL =          0x0001; // bit 0 (group 1) (Note: also used for max level!)
+    const TRIM =         0x0002; // bit 1 (group 1)
+    const CRUMB =        0x0004; // bit 2 (group 1)
+    const SIBLING =      0x0008; // bit 3 (group 1)
+    const NUMCLASS =     0x0010; // bit 4
+    const ALLINFO =      0x0020; // bit 5
+    const NOCACHE =      0x0040; // bit 6
+    const PRETTY =       0x0080; // bit 7
+    const ESCAPE =       0x0100; // bit 8
+    const NOESCAPE =          0; // NOOP, unnecessary with WB 2.6.7+
+    const NOBUFFER =     0x0200; // bit 9
+    const CURRTREE =     0x0400; // bit 10
+    const SHOWHIDDEN =   0x0800; // bit 11
+    const XHTML_STRICT = 0x1000; // bit 12
+    const NO_TITLE =     0x2000; // bit 13
+    const _GROUP_1 =     0x000F; // exactly one flag from group 1 is required
+    const CONDITIONAL =  'if\s*\(([^\)]+)\)\s*{([^}]*)}\s*(?:else\s*{([^}]*)}\s*)?';
+    const COND_TERM =    '\s*(\w+)\s*(<|<=|==|=|=>|>|!=)\s*([\w\-]+)\s*';
+}
+
+// Implement support for page_menu and show_menu using show_menu2. If you remove
+// the comments characters from the beginning of the following include, all menu
+// functions in Website Baker will be implemented using show_menu2. While it is
+// commented out, the original WB functions will be used.
+//include('legacy.php');
+
+// This class is the default menu formatter for sm2. If desired, you can
+// create your own formatter class and pass the object into show_menu2
+// as $aItemFormat.
+
+
+class SM2_Formatter
+{
+    var $output;
+    var $flags;
+    var $itemOpen;
+    var $itemClose;
+    var $menuOpen;
+    var $menuClose;
+    var $topItemOpen;
+    var $topMenuOpen;
+
+    var $isFirst;
+    var $page;
+    var $url;
+    var $currSib;
+    var $sibCount;
+    var $currClass;
+    var $prettyLevel;
+
+    // output the data
+    function output($aString) {
+        if ($this->flags & SM2::NOBUFFER) {
+            echo $aString;
+        } else {
+            $this->output .= $aString;
+        }
+    }
+
+    // set the default values for all of our formatting items
+    function set($aFlags, $aItemOpen, $aItemClose, $aMenuOpen, $aMenuClose, $aTopItemOpen, $aTopMenuOpen) {
+        $this->flags        = $aFlags;
+        $this->itemOpen     = is_string($aItemOpen)    ? $aItemOpen    : '[li][a][menu_title]</a>';
+        $this->itemClose    = is_string($aItemClose)   ? $aItemClose   : '</li>';
+        $this->menuOpen     = is_string($aMenuOpen)    ? $aMenuOpen    : '[ul]';
+        $this->menuClose    = is_string($aMenuClose)   ? $aMenuClose   : '</ul>';
+        $this->topItemOpen  = is_string($aTopItemOpen) ? $aTopItemOpen : $this->itemOpen;
+        $this->topMenuOpen  = is_string($aTopMenuOpen) ? $aTopMenuOpen : $this->menuOpen;
+    }
+
+    // initialize the state of the formatter before anything is output
+    function initialize() {
+        $this->output = '';
+        $this->prettyLevel = 0;
+        if ($this->flags & SM2::PRETTY) {
+            $this->output("\n<!-- show_menu2 -->");
+        }
+    }
+
+    // start a menu
+    function startList(&$aPage, &$aUrl) {
+        $currClass = '';
+        $currItem = $this->menuOpen;
+
+        // use the top level menu open if this is the first menu
+        if ($this->topMenuOpen) {
+            $currItem = $this->topMenuOpen;
+            $currClass .= ' menu-top';
+            $this->topMenuOpen = false;
+        }
+
+        // add the numbered menu class only if requested
+        if (($this->flags & SM2::NUMCLASS) == SM2::NUMCLASS) {
+            $currClass .= ' menu-'.$aPage['level'];
+        }
+
+        $this->prettyLevel += 1;
+
+        // replace all keywords in the output
+        if ($this->flags & SM2::PRETTY) {
+            $this->output("\n".str_repeat(' ',$this->prettyLevel).
+                $this->format($aPage, $aUrl, $currItem, $currClass));
+        }
+        else {
+            $this->output($this->format($aPage, $aUrl, $currItem, $currClass));
+        }
+
+        $this->prettyLevel += 3;
+    }
+
+    // start an item within the menu
+    function startItem(&$aPage, &$aUrl, $aCurrSib, $aSibCount) {
+        // generate our class list
+        $currClass = '';
+        if (($this->flags & SM2::NUMCLASS) == SM2::NUMCLASS) {
+            $currClass .= ' menu-'.$aPage['level'];
+        }
+        if (array_key_exists('sm2_has_child', $aPage)) {
+            // not set if false, so existence = true
+            $currClass .= ' menu-expand';
+        }
+        if (array_key_exists('sm2_is_curr', $aPage)) {
+            $currClass .= ' menu-current';
+        }
+        elseif (array_key_exists('sm2_is_parent', $aPage)) {
+            // not set if false, so existence = true
+            $currClass .= ' menu-parent';
+        }
+        elseif (array_key_exists('sm2_is_sibling', $aPage)) {
+            // not set if false, so existence = true
+            $currClass .= ' menu-sibling';
+        }
+        elseif (array_key_exists('sm2_child_level',$aPage)) {
+            // not set if not a child
+            $currClass .= ' menu-child';
+            if (($this->flags & SM2::NUMCLASS) == SM2::NUMCLASS) {
+                $currClass .= ' menu-child-'.($aPage['sm2_child_level']-1);
+            }
+        }
+        if ($aCurrSib == 1) {
+            $currClass .= ' menu-first';
+        }
+        if ($aCurrSib == $aSibCount) {
+            $currClass .= ' menu-last';
+        }
+
+        // use the top level item if this is the first item
+        $currItem = $this->itemOpen;
+        if ($this->topItemOpen) {
+            $currItem = $this->topItemOpen;
+            $this->topItemOpen = false;
+        }
+
+        // replace all keywords in the output
+        if ($this->flags & SM2::PRETTY) {
+            $this->output("\n".str_repeat(' ',$this->prettyLevel));
+        }
+        $this->output($this->format($aPage, $aUrl, $currItem, $currClass, $aCurrSib, $aSibCount));
+    }
+
+    // find and replace all keywords, setting the state variables first
+    function format(&$aPage, &$aUrl, &$aCurrItem, &$aCurrClass,
+        $aCurrSib = 0, $aSibCount = 0)
+    {
+        $this->page      = &$aPage;
+        $this->url       = &$aUrl;
+        $this->currClass = trim($aCurrClass);
+        $this->currSib   = $aCurrSib;
+        $this->sibCount  = $aSibCount;
+
+        $item = $this->format2($aCurrItem);
+
+        unset($this->page);
+        unset($this->url);
+        unset($this->currClass);
+
+        return $item;
+    }
+
+    // find and replace all keywords
+    function format2(&$aCurrItem) {
+        if (!is_string($aCurrItem)) return '';
+        return preg_replace_callback(
+            '@\[('.
+                'a|ac|/a|li|/li|ul|/ul|menu_title|menu_icon_0|menu_icon_1|'.
+                'page_title|page_icon|url|target|page_id|tooltip|'.
+                'parent|level|sib|sibCount|class|description|keywords|'.
+                SM2::CONDITIONAL.
+            ')\]@',
+            array($this, 'replace'),
+            $aCurrItem);
+    }
+
+    // replace the keywords
+    function replace($aMatches) {
+        $aMatch = $aMatches[1];
+        $retval = '['.$aMatch.'=UNKNOWN]';
+        switch ($aMatch) {
+        case 'a':
+            $retval = '<a href="'.$this->url.'"';
+            // break; // ignore 'break' to add the rest of <a>-tag
+        case 'ac':
+            if( substr($retval, 0, 2) != '<a'){
+                $retval = '<a href="'.$this->url.'" class="'.$this->currClass.'"';
+            }
+            if(($this->flags & SM2::NO_TITLE)) {
+                $retval .= ' title="'.$this->page['tooltip'].'"';
+            }
+            if(!($this->flags & SM2::XHTML_STRICT)) {
+                $retval .= ' target="'.$this->page['target'].'"';
+            }
+            $retval .= '>';
+            break;
+        case '/a':
+            $retval = '</a>'; break;
+        case 'li':
+            $retval = '<li class="'.$this->currClass.'">'; break;
+        case '/li':
+            $retval = '</li>'; break;
+        case 'ul':
+            $retval = '<ul class="'.$this->currClass.'">'; break;
+        case '/ul':
+            $retval = '</ul>'; break;
+        case 'url':
+            $retval = $this->url; break;
+        case 'sib':
+            $retval = $this->currSib; break;
+        case 'sibCount':
+            $retval = $this->sibCount; break;
+        case 'class':
+            $retval = $this->currClass; break;
+        default:
+            if (array_key_exists($aMatch, $this->page)) {
+                if ($this->flags & SM2::ESCAPE) {
+                    $retval = htmlspecialchars($this->page[$aMatch], ENT_QUOTES);
+                }
+                else {
+                    $retval = $this->page[$aMatch];
+                }
+            }
+            if (preg_match('/'.SM2::CONDITIONAL.'/', $aMatch, $rgMatches)) {
+                $retval = $this->replaceIf($rgMatches[1], $rgMatches[2], $rgMatches[3]);
+            }
+        }
+        return $retval;
+    }
+
+    // conditional replacement
+    function replaceIf(&$aExpression, &$aIfValue, &$aElseValue) {
+        // evaluate all of the tests in the conditional (we don't do short-circuit
+        // evaluation) and replace the string test with the boolean result
+        $rgTests = preg_split('/(\|\||\&\&)/', $aExpression, -1, PREG_SPLIT_DELIM_CAPTURE);
+        for ($n = 0; $n < count($rgTests); $n += 2) {
+            if (preg_match('/'.SM2::COND_TERM.'/', $rgTests[$n], $rgMatches)) {
+                $rgTests[$n] = $this->ifTest($rgMatches[1], $rgMatches[2], $rgMatches[3]);
+            }
+            else {
+                @error_logs("show_menu2 error: conditional expression is invalid!");
+                $rgTests[$n] = false;
+            }
+        }
+
+        // combine all test results for a final result
+        $ok = $rgTests[0];
+        for ($n = 1; $n+1 < count($rgTests); $n += 2) {
+            if ($rgTests[$n] == '||') {
+                $ok = $ok || $rgTests[$n+1];
+            }
+            else {
+                $ok = $ok && $rgTests[$n+1];
+            }
+        }
+
+        // return the formatted expression if the test succeeded
+        return $ok ? $this->format2($aIfValue) : $this->format2($aElseValue);
+    }
+
+    // conditional test
+    function ifTest(&$aKey, &$aOperator, &$aValue) {
+        global $wb;
+
+        // find the correct operand
+        $operand = false;
+        switch($aKey) {
+        case 'class':
+            // we need to wrap the class names in spaces so we can test for a unique
+            // class name that will not match prefixes or suffixes. Same must be done
+            // for the value we are testing.
+            $operand = " $this->currClass ";
+            break;
+        case 'target':
+            $operand = $this->page['target'];
+            break;
+        case 'sib':
+            $operand = $this->currSib;
+            if ($aValue == 'sibCount') {
+                $aValue = $this->sibCount;
+            }
+            break;
+        case 'sibCount':
+            $operand = $this->sibCount;
+            break;
+        case 'level':
+            $operand = $this->page['level'];
+            switch ($aValue) {
+            case 'root':    $aValue = 0; break;
+            case 'granny':  $aValue = $wb->page['level']-2; break;
+            case 'parent':  $aValue = $wb->page['level']-1; break;
+            case 'current': $aValue = $wb->page['level'];   break;
+            case 'child':   $aValue = $wb->page['level']+1; break;
+            }
+            if ($aValue < 0) $aValue = 0;
+            break;
+        case 'id':
+            $operand = $this->page['page_id'];
+            switch ($aValue) {
+            case 'parent':  $aValue = $wb->page['parent'];  break;
+            case 'current': $aValue = $wb->page['page_id']; break;
+            }
+            break;
+        default:
+            return '';
+        }
+
+        // do the test
+        $ok = false;
+        switch ($aOperator) {
+        case '<':
+            $ok = ($operand < $aValue);
+            break;
+        case '<=':
+            $ok = ($operand <= $aValue);
+            break;
+        case '=':
+        case '==':
+        case '!=':
+            if ($aKey == 'class') {
+                $ok = strstr($operand, " $aValue ") !== FALSE;
+            }
+            else {
+                $ok = ($operand == $aValue);
+            }
+            if ($aOperator == '!=') {
+                $ok = !$ok;
+            }
+            break;
+        case '>=':
+            $ok = ($operand >= $aValue);
+        case '>':
+            $ok = ($operand > $aValue);
+        }
+
+        return $ok;
+    }
+
+    // finish the current menu item
+    function finishItem() {
+        if ($this->flags & SM2::PRETTY) {
+            $this->output(str_repeat(' ',$this->prettyLevel).$this->itemClose);
+        }
+        else {
+            $this->output($this->itemClose);
+        }
+    }
+
+    // finish the current menu
+    function finishList() {
+        $this->prettyLevel -= 3;
+
+        if ($this->flags & SM2::PRETTY) {
+            $this->output("\n".str_repeat(' ',$this->prettyLevel).$this->menuClose."\n");
+        }
+        else {
+            $this->output($this->menuClose);
+        }
+
+        $this->prettyLevel -= 1;
+    }
+
+    // cleanup the state of the formatter after everything has been output
+    function finalize() {
+        if ($this->flags & SM2::PRETTY) {
+            $this->output("\n");
+        }
+    }
+
+    // return the output
+    function getOutput() {
+        return $this->output;
+    }
+};
+
+function error_logs($error_str)
+{
+                $log_error = true;
+                if ( ! function_exists('error_log') )
+                        $log_error = false;
+
+                $log_file = @ini_get('error_log');
+                if ( !empty($log_file) && ('syslog' != $log_file) && !@is_writable($log_file) )
+                        $log_error = false;
+
+                if ( $log_error )
+                        @error_log($error_str, 0);
+}
+
+function show_menu2(
+    $aMenu          = 0,
+    $aStart         = SM2::ROOT,
+    $aMaxLevel      = -1999, // SM2::CURR+1
+    $aOptions       = SM2::TRIM,
+    $aItemOpen      = false,
+    $aItemClose     = false,
+    $aMenuOpen      = false,
+    $aMenuClose     = false,
+    $aTopItemOpen   = false,
+    $aTopMenuOpen   = false
+    )
+{
+    global $wb;
+    $database = WbDatabase::getInstance();
+    $iQueryStart = $database->getQueryCount;
+    // extract the flags and set $aOptions to an array
+    $flags = 0;
+    if (is_int($aOptions)) {
+        $flags = $aOptions;
+        $aOptions = array();
+    }
+    else if (isset($aOptions['flags'])) {
+        $flags = $aOptions['flags'];
+    }
+    else {
+        $flags = SM2::TRIM;
+        $aOptions = array();
+        @error_logs('show_menu2 error: $aOptions is invalid. No flags supplied!');
+    }
+
+    // ensure we have our group 1 flag, we don't check for the "exactly 1" part, but
+    // we do ensure that they provide at least one.
+    if (0 == ($flags & SM2::_GROUP_1)) {
+        @error_logs('show_menu2 error: $aOptions is invalid. No flags from group 1 supplied!');
+        $flags |= SM2::TRIM; // default to TRIM
+    }
+
+    // search page results don't have any of the page data loaded by WB, so we load it
+    // ourselves using the referrer ID as the current page
+    $CURR_PAGE_ID = defined('REFERRER_ID') ? REFERRER_ID : PAGE_ID;
+    if (count($wb->page) == 0 && defined('REFERRER_ID') && REFERRER_ID > 0) {
+        global $database;
+        $sql = 'SELECT * FROM `'.TABLE_PREFIX.'pages` WHERE `page_id` = '.REFERRER_ID.'';
+        $result = $database->query($sql);
+        if ($result->numRows() == 1) {
+            $wb->page = $result->fetchRow();
+        }
+        unset($result);
+    }
+
+    // fix up the menu number to default to the menu number
+    // of the current page if no menu has been supplied
+    if ($aMenu == 0) {
+        $aMenu = $wb->page['menu'] == '' ? 1 : $wb->page['menu'];
+    }
+
+    // Set some of the $wb->page[] settings to defaults if not set
+    $pageLevel  = $wb->page['level']  == '' ? 0 : $wb->page['level'];
+    $pageParent = $wb->page['parent'] == '' ? 0 : $wb->page['parent'];
+
+    // adjust the start level and start page ID as necessary to
+    // handle the special values that can be passed in as $aStart
+    $aStartLevel = 0;
+    if ($aStart < SM2::ROOT) {   // SM2::CURR+N
+        if ($aStart == SM2::CURR) {
+            $aStartLevel = $pageLevel;
+            $aStart = $pageParent;
+        }
+        else {
+            $aStartLevel = $pageLevel + $aStart - SM2::CURR;
+            $aStart = $CURR_PAGE_ID;
+        }
+    }
+    elseif ($aStart < 0) {   // SM2::ROOT+N
+        $aStartLevel = $aStart - SM2::ROOT;
+        $aStart = 0;
+    }
+
+    // we get the menu data once and store it in a global variable. This allows
+    // multiple calls to show_menu2 in a single page with only a single call to
+    // the database. If this variable exists, then we have already retrieved all
+    // of the information and processed it, so we don't need to do it again.
+    if (($flags & SM2::NOCACHE) != 0
+        || !array_key_exists('show_menu2_data', $GLOBALS)
+        || !array_key_exists($aMenu, $GLOBALS['show_menu2_data']))
+    {
+        global $database;
+
+        // create an array of all parents of the current page. As the page_trail
+        // doesn't include the theoretical root element 0, we add it ourselves.
+        $rgCurrParents = explode(",", '0,'.$wb->page['page_trail']);
+        array_pop($rgCurrParents); // remove the current page
+        $rgParent = array();
+
+        // if the caller wants all menus gathered together (e.g. for a sitemap)
+        // then we don't limit our SQL query
+        $menuLimitSql = ' AND `menu`='.$aMenu;
+        if ($aMenu == SM2::ALLMENU) {
+            $menuLimitSql = '';
+        }
+
+        // we only load the description and keywords if we have been told to,
+        // this cuts the memory load for pages that don't use them. Note that if
+        // we haven't been told to load these fields the *FIRST TIME* show_menu2
+        // is called (i.e. where the database is loaded) then the info won't
+        // exist anyhow.
+        $fields  = '`parent`,`page_id`,`menu_title`,`page_title`,`link`,`target`,';
+        $fields .= '`level`,`visibility`,`viewing_groups`,`viewing_users`,';
+        $fields .= '`menu_icon_0`,`menu_icon_1`,`page_icon`,`tooltip`';
+        if ($flags & SM2::ALLINFO) {
+            $fields = '*';
+        }
+
+        // we request all matching rows from the database for the menu that we
+        // are about to create it is cheaper for us to get everything we need
+        // from the database once and create the menu from memory then make
+        // multiple calls to the database.
+        $sql  = 'SELECT '.$fields.' FROM `'.TABLE_PREFIX.'pages` ';
+        $sql .= 'WHERE '.$wb->extra_where_sql.' '.$menuLimitSql.' ';
+        $sql .= 'ORDER BY `level` ASC, `position` ASC';
+        $sql = str_replace('hidden', 'IGNOREME', $sql); // we want the hidden pages
+        $oRowset = $database->query($sql);
+        if (is_object($oRowset) && $oRowset->numRows() > 0) {
+            // create an in memory array of the database data based on the item's parent.
+            // The array stores all elements in the correct display order.
+            while ($page = $oRowset->fetchRow()) {
+                // ignore all pages that the current user is not permitted to view
+                if(version_compare(WB_VERSION, '2.7', '>=')) { // WB >= 2.7
+                    // 1. hidden pages aren't shown unless they are on the current page
+                    if ($page['visibility'] == 'hidden') {
+                        $page['sm2_hide'] = true;
+                    }
+
+                    // 2. all pages with no active sections (unless it is the top page) are ignored
+                    else if (!$wb->page_is_active($page) && $page['link'] != $wb->default_link && !INTRO_PAGE) {
+                        continue;
+                    }
+
+                    // 3. all pages not visible to this user (unless always visible to registered users) are ignored
+                    else if (!$wb->page_is_visible($page) && $page['visibility'] != 'registered') {
+                        continue;
+                    }
+                }
+                if(isset($page['page_icon']) && $page['page_icon'] != '') {
+                    $page['page_icon'] = WB_URL.$page['page_icon'];
+                }
+                if(isset($page['menu_icon_0']) && $page['menu_icon_0'] != '') {
+                    $page['menu_icon_0'] = WB_URL.$page['menu_icon_0'];
+                }
+                if(isset($page['menu_icon_1']) && $page['menu_icon_1'] != '') {
+                    $page['menu_icon_1'] = WB_URL.$page['menu_icon_1'];
+                }
+
+                if(!isset($page['tooltip'])) { $page['tooltip'] = $page['page_title']; }
+                // ensure that we have an array entry in the table to add this to
+                $idx = $page['parent'];
+                if (!array_key_exists($idx, $rgParent)) {
+                    $rgParent[$idx] = array();
+                }
+
+                // mark our current page as being on the current path
+                if ($page['page_id'] == $CURR_PAGE_ID) {
+                    $page['sm2_is_curr'] = true;
+                    $page['sm2_on_curr_path'] = true;
+                    if ($flags & SM2::SHOWHIDDEN)
+                    {
+                        // show hidden pages if active and SHOWHIDDEN flag supplied
+                        unset($page['sm2_hide']);
+                    }
+                }
+
+                // mark parents of the current page as such
+                if (in_array($page['page_id'], $rgCurrParents)) {
+                    $page['sm2_is_parent'] = true;
+                    $page['sm2_on_curr_path'] = true;
+                    if ($flags & SM2::SHOWHIDDEN)
+                    {
+                        // show hidden pages if active and SHOWHIDDEN flag supplied
+                        unset($page['sm2_hide']); // don't hide a parent page
+                    }
+                }
+
+                // add the entry to the array
+                $rgParent[$idx][] = $page;
+            }
+        }
+        unset($oRowset);
+
+        // mark all elements that are siblings of any element on the current path
+        foreach ($rgCurrParents as $x) {
+            if (array_key_exists($x, $rgParent)) {
+                foreach (array_keys($rgParent[$x]) as $y) {
+                    $mark =& $rgParent[$x][$y];
+                    $mark['sm2_path_sibling'] = true;
+                    unset($mark);
+                }
+            }
+        }
+
+        // mark all elements that have children and are siblings of the current page
+        $parentId = $pageParent;
+        foreach (array_keys($rgParent) as $x) {
+            $childSet =& $rgParent[$x];
+            foreach (array_keys($childSet) as $y) {
+                $mark =& $childSet[$y];
+                if (array_key_exists($mark['page_id'], $rgParent)) {
+                    $mark['sm2_has_child'] = true;
+                }
+                if ($mark['parent'] == $parentId && $mark['page_id'] != $CURR_PAGE_ID) {
+                    $mark['sm2_is_sibling'] = true;
+                }
+                unset($mark);
+            }
+            unset($childSet);
+        }
+
+        // mark all children of the current page. We don't do this when
+        // $CURR_PAGE_ID is 0, as 0 is the parent of everything.
+        // $CURR_PAGE_ID == 0 occurs on special pages like search results
+        // when no referrer is available.s
+        if ($CURR_PAGE_ID != 0) {
+            sm2_mark_children($rgParent, $CURR_PAGE_ID, 1);
+        }
+
+        // store the complete processed menu data as a global. We don't
+        // need to read this from the database anymore regardless of how
+        // many menus are displayed on the same page.
+        if (!array_key_exists('show_menu2_data', $GLOBALS)) {
+            $GLOBALS['show_menu2_data'] = array();
+        }
+        $GLOBALS['show_menu2_data'][$aMenu] =& $rgParent;
+        unset($rgParent);
+    }
+
+    // adjust $aMaxLevel to the level number of the final level that
+    // will be displayed. That is, we display all levels <= aMaxLevel.
+    if ($aMaxLevel == SM2::ALL) {
+        $aMaxLevel = 1000;
+    }
+    elseif ($aMaxLevel < 0) {   // SM2::CURR+N
+        $aMaxLevel += $pageLevel - SM2::CURR;
+    }
+    elseif ($aMaxLevel >= SM2::MAX) { // SM2::MAX+N
+        $aMaxLevel += $aStartLevel - SM2::MAX;
+        if ($aMaxLevel > $pageLevel) {
+            $aMaxLevel = $pageLevel;
+        }
+    }
+    else {  // SM2::START+N
+        $aMaxLevel += $aStartLevel - SM2::START;
+    }
+
+    // generate the menu
+    $retval = false;
+    if (array_key_exists($aStart, $GLOBALS['show_menu2_data'][$aMenu])) {
+        $formatter = $aItemOpen;
+        if (!is_object($aItemOpen)) {
+            static $sm2formatter;
+            if (!isset($sm2formatter)) {
+                $sm2formatter = new SM2_Formatter;
+            }
+            $formatter = $sm2formatter;
+            $formatter->set($flags, $aItemOpen, $aItemClose,
+                $aMenuOpen, $aMenuClose, $aTopItemOpen, $aTopMenuOpen);
+        }
+
+        // adjust the level until we show everything and ignore the SM2_TRIM flag.
+        // Usually this will be less than the start level to disable it.
+        $showAllLevel = $aStartLevel - 1;
+        if (isset($aOptions['notrim'])) {
+            $showAllLevel = $aStartLevel + $aOptions['notrim'];
+        }
+
+        // display the menu
+        $formatter->initialize();
+        sm2_recurse(
+            $GLOBALS['show_menu2_data'][$aMenu],
+            $aStart,    // parent id to start displaying sub-menus
+            $aStartLevel, $showAllLevel, $aMaxLevel, $flags,
+            $formatter);
+        $formatter->finalize();
+
+        // if we are returning something, get the data
+        if (($flags & SM2::NOBUFFER) == 0) {
+            $retval = $formatter->getOutput();
+        }
+    }
+
+    // clear the data if we aren't caching it
+    if (($flags & SM2::NOCACHE) != 0) {
+        unset($GLOBALS['show_menu2_data'][$aMenu]);
+    }
+    if(defined('DEBUG') && (DEBUG)) {
+        $iQueriesDone = $database->getQueryCount - $iQueryStart;
+        return $retval."\n".'<!-- Queries: '.$iQueriesDone.' -->'."\n";
+    }
+    return $retval;
+}
+
+function sm2_mark_children(&$rgParent, $aStart, $aChildLevel)
+{
+    if (array_key_exists($aStart, $rgParent)) {
+        foreach (array_keys($rgParent[$aStart]) as $y) {
+            $mark =& $rgParent[$aStart][$y];
+            $mark['sm2_child_level'] = $aChildLevel;
+            $mark['sm2_on_curr_path'] = true;
+            sm2_mark_children($rgParent, $mark['page_id'], $aChildLevel+1);
+        }
+    }
+}
+
+function sm2_recurse(
+    &$rgParent, $aStart,
+    $aStartLevel, $aShowAllLevel, $aMaxLevel, $aFlags,
+    &$aFormatter
+    )
+{
+    global $wb;
+
+    // on entry to this function we know that there are entries for this
+    // parent and all entries for that parent are being displayed. We also
+    // need to check if any of the children need to be displayed too.
+    $isListOpen = false;
+    $currentLevel = $wb->page['level'] == '' ? 0 : $wb->page['level'];
+
+    // get the number of siblings skipping the hidden pages so we can pass
+    // this in and check if the item is first or last
+    $sibCount = 0;
+    foreach ($rgParent[$aStart] as $page) {
+        if (!array_key_exists('sm2_hide', $page)) $sibCount++;
+    }
+
+    $currSib = 0;
+    foreach ($rgParent[$aStart] as $page) {
+        // skip all hidden pages
+        if (array_key_exists('sm2_hide', $page)) { // not set if false, so existence = true
+            continue;
+        }
+
+        $currSib++;
+
+        // skip any elements that are lower than the maximum level
+        $pageLevel = $page['level'];
+        if ($pageLevel > $aMaxLevel) {
+            continue;
+        }
+
+        // this affects ONLY the top level
+        if ($aStart == 0 && ($aFlags & SM2::CURRTREE)) {
+            if (!array_key_exists('sm2_on_curr_path', $page)) { // not set if false, so existence = true
+                continue;
+            }
+            $sibCount = 1;
+        }
+
+        // trim the tree as appropriate
+        if ($aFlags & SM2::SIBLING) {
+            // parents, and siblings and children of current only
+            if (!array_key_exists('sm2_on_curr_path', $page)      // not set if false, so existence = true
+                && !array_key_exists('sm2_is_sibling', $page)     // not set if false, so existence = true
+                && !array_key_exists('sm2_child_level', $page)) { // not set if false, so existence = true
+                continue;
+            }
+        }
+        else if ($aFlags & SM2::TRIM) {
+            // parents and siblings of parents
+            if ($pageLevel > $aShowAllLevel  // permit all levels to be shown
+                && !array_key_exists('sm2_on_curr_path', $page)    // not set if false, so existence = true
+                && !array_key_exists('sm2_path_sibling', $page)) {  // not set if false, so existence = true
+                continue;
+            }
+        }
+        elseif ($aFlags & SM2::CRUMB) {
+            // parents only
+            if (!array_key_exists('sm2_on_curr_path', $page)    // not set if false, so existence = true
+                || array_key_exists('sm2_child_level', $page)) {  // not set if false, so existence = true
+                continue;
+            }
+        }
+
+        // depth first traverse
+        $nextParent = $page['page_id'];
+
+        // display the current element if we have reached the start level
+        if ($pageLevel >= $aStartLevel) {
+            // massage the link into the correct form
+            if(!INTRO_PAGE && $page['link'] == $wb->default_link) {
+                $url = WB_URL.'/';
+            }
+            else {
+                $url = $wb->page_link($page['link']);
+            }
+
+            // we open the list only when we absolutely need to
+            if (!$isListOpen) {
+                $aFormatter->startList($page, $url);
+                $isListOpen = true;
+            }
+
+            $aFormatter->startItem($page, $url, $currSib, $sibCount);
+        }
+
+        // display children as appropriate
+        if ($pageLevel + 1 <= $aMaxLevel
+            && array_key_exists('sm2_has_child', $page)) {  // not set if false, so existence = true
+            sm2_recurse(
+                $rgParent, $nextParent, // parent id to start displaying sub-menus
+                $aStartLevel, $aShowAllLevel, $aMaxLevel, $aFlags,
+                $aFormatter);
+        }
+
+        // close the current element if appropriate
+        if ($pageLevel >= $aStartLevel) {
+            $aFormatter->finishItem($pageLevel, $page);
+        }
+    }
+
+    // close the list if we opened one
+    if ($isListOpen) {
+        $aFormatter->finishList();
+    }
+}
\ No newline at end of file

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/include.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/info.ini
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/info.ini	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/info.ini	(revision 2114)
@@ -0,0 +1,22 @@
+;
+; info file for snippet 'show_menu2'
+;
+[info]
+type            = "snippet"
+directory       = "ShowMenu2"
+name            = "Show-Menu-2 Menu generator"
+version         = "4.10.1"
+author          = "Brodie Thiesfield, Manuela v.d.Decken"
+license         = "GNU GPLv.2"
+license_terms   = "GNU General Public License Version 2"
+description     = "A code snippet for the Website Baker CMS providing a complete replacement
+for the builtin menu functions. See <a href="http://code.jellycan.com/show_menu2/" target="_blank">
+http://code.jellycan.com/show_menu2/</a> for details or view the <a href="'.WB_URL
+.'/modules/show_menu2/README.en.txt" target="_blank">readme</a> file."
+ 
+; for whitch platform the addon is usable
+[platform]
+name            = "WebsiteBaker"
+versions        = "2.8.4"
+minPhp          = "5.4"
+;
Index: branches/2.8.x/wb/modules/ShowMenu2/legacy.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/legacy.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/legacy.php	(revision 2114)
@@ -0,0 +1,192 @@
+<?php
+/**
+ *
+ * @category        module
+ * @package         show_menu2
+ * @author          WebsiteBaker Project
+ * @copyright       2004-2009, Ryan Djurovich
+ * @copyright       2009-2011, Website Baker Org. e.V.
+ * @link			http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.7.0 | 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource		$HeadURL$
+ * @lastmodified    $Date$
+ *
+ */
+
+/*
+    This file provides backward compatibility between show_menu2 and the
+    old functions show_menu() and menu(). Note that it is highly recommended 
+    for you to update your templates to use show_menu2 directly.
+ */    
+
+/* ----------------------------------------------------------------------------
+   show_menu
+   
+ From: http://forum.websitebaker.org/index.php/topic,2251.msg13978.html#msg13978  
+ 
+ * By calling it multiple times, you can have one menu just
+ * showing the root level, one for the sub-pages, and so on
+ * The order of the arguments has been changed compared
+ * to the page_menu() function, so read carefully the list
+ * of arguments!
+ * To just display the standard menu, use
+ * <?php show_menu(); ?> within your template's html code.
+ * You don't normally need anymore than the first four arguments.
+ * Usual calls would be (inside php code!)
+ * show_menu(1,0,-1,false); - displays the complete page tree
+ * show_menu(1,1,1); - show only first sub level
+ * show_menu(1,1,-1); -    show an expanding/collapsing menu tree starting at level 1
+ * Have fun experimenting!
+ *
+ * Full list of arguments:
+ * 1. $menu_number:   With activitated "multiple menu" feature
+ *                  you can choose which menu will be displayed
+ *                  default: 1
+ * 2. $start_level: The depth level of the root of the displayed
+ *               menu tree. Defaults to '0', which is the top level.
+ *                  '1' will show all pages starting from the first sub level.
+ * 3. $recurse:     Gives the maximum number of levels to be displayed. Default
+ *                  is '-1' which means 'all'.
+ * 4. $collapse:    Specifies, whether the menu tree shall be
+ *               expandable/collapsible (if set to 'true')
+ *               or complete (all pages being displayed) if set to 'false'
+ * 5. $item_template: Gives the possibility to specify the html code that is
+ *                  displayed before displaying sub-pages
+ * 6. $item_footer: The html code to appear after sub-pages were displayed.
+ * 7. $menu_header: The html code to appear before the entire menu code and each
+ *               sub tree.
+ * 8. $menu_footer: The html code to appear after the entire menu code and each
+ *               sub tree.
+ * 9. $default_class: The (CSS) class of every menu item except the currently viewed page
+ * 10. $current_class: The class of the currently viewed page
+ * 11. $parent:    (used internally) The page_id of the menu's root node, defaults is '0' (root level)
+ */
+
+// Must include code to stop this file being access directly
+if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
+ 
+class SM2_ShowMenuFormatter
+{
+    var $output;
+    var $itemTemplate;
+    var $itemFooter;
+    var $menuHeader;
+    var $menuFooter;
+    var $defaultClass;
+    var $currentClass;
+    
+    function output($aString) {
+        if ($this->flags & SM2::NOBUFFER) {
+            echo $aString;
+        } else {
+            $this->output .= $aString;
+        }
+    }
+    function initialize() { $this->output = ''; }
+    function startList($aPage, $aUrl) { 
+        echo $this->menuHeader;
+    }
+    function startItem($aPage, $aUrl, $aCurrSib, $aSibCount) { 
+        // determine the class string to use
+        $thisClass = $this->defaultClass;
+        if ($aPage['page_id'] == PAGE_ID) {
+            $thisClass = $this->currentClass;
+        }
+        
+        // format and display this item
+        $item = str_replace( 
+                array(
+                    '[a]','[/a]','[menu_title]','[page_title]','[url]',
+                    '[target]','[class]'
+                    ),
+                array(
+                    "<a href='$aUrl' target='".$aPage['target']."'>", '</a>',
+                    $aPage['menu_title'], $aPage['page_title'], $aUrl, 
+                    $aPage['target'], $thisClass
+                    ),
+                $this->itemTemplate);
+        echo $item;
+    }
+    function finishItem() { 
+        echo $this->itemFooter;
+    }
+    function finishList() { 
+        echo $this->menuFooter;
+    }
+    function finalize() { }
+    function getOutput() {
+        return $this->output;
+    }
+}
+
+function show_menu(
+    $aMenu          = 1, 
+    $aStartLevel    = 0, 
+    $aRecurse       = -1, 
+    $aCollapse      = true,
+    $aItemTemplate  = '<li><span[class]>[a][menu_title][/a]</span>',
+    $aItemFooter    = '</li>',
+    $aMenuHeader    = '<ul>',
+    $aMenuFooter    = '</ul>',
+    $aDefaultClass  = ' class="menu_default"',
+    $aCurrentClass  = ' class="menu_current"',
+    $aParent        = 0
+    )
+{
+    static $formatter;
+    if (!isset($formatter)) {
+        $formatter = new SM2_ShowMenuFormatter;
+    }
+    
+    $formatter->itemTemplate  = $aItemTemplate;
+    $formatter->itemFooter    = $aItemFooter;  
+    $formatter->menuHeader    = $aMenuHeader;  
+    $formatter->menuFooter    = $aMenuFooter;  
+    $formatter->defaultClass  = $aDefaultClass;
+    $formatter->currentClass  = $aCurrentClass;
+    
+    $start = SM2::ROOT + $aStartLevel;
+    if ($aParent != 0) {
+        $start = $aParent;
+    }
+
+    $maxLevel = 0;
+    if ($aRecurse == 0) {
+        return;
+    }
+    if ($aRecurse < 0) {
+        $maxLevel = SM2::ALL;
+    }
+    else {
+        $maxLevel = SM2::START + $aRecurse - 1;
+    }
+    
+    $flags = $aCollapse ? SM2::TRIM : SM2::ALL;
+    
+    // special case for default case
+    if ($aStartLevel == 0 && $aRecurse == -1 && $aCollapse) {
+        $maxLevel = SM2::CURR + 1;
+    }
+
+    show_menu2($aMenu, $start, $maxLevel, $flags, $formatter);
+}
+
+function page_menu(
+    $aParent = 0, 
+    $menu_number = 1, 
+    $item_template = '<li[class]>[a][menu_title][/a]</li>', 
+    $menu_header = '<ul>', 
+    $menu_footer = '</ul>', 
+    $default_class = ' class="menu_default"', 
+    $current_class = ' class="menu_current"', 
+    $recurse = LEVEL    // page['level']
+    ) 
+{
+    show_menu($menu_number, 0, $recurse+2, true, $item_template, '', 
+        $menu_header, $menu_footer, $default_class, $current_class, $aParent);
+}
+
+?>

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/legacy.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/install.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/install.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/install.php	(revision 2114)
@@ -0,0 +1,21 @@
+<?php
+/**
+ *
+ * @category        modules
+ * @package         show_menu2
+ * @author          Independend-Software-Team
+ * @author          WebsiteBaker Project
+ * @copyright       2004-2009, Ryan Djurovich
+ * @copyright       2009-2011, Website Baker Org. e.V.
+ * @link            http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource      $HeadURL$
+ * @lastmodified    $Date$
+ *
+ */
+
+// Must include code to stop this file being access directly
+if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/install.php
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/index.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/index.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/index.php	(revision 2114)
@@ -0,0 +1,19 @@
+<?php
+/**
+ *
+ * @category        module
+ * @package         show_menu2
+ * @author          WebsiteBaker Project
+ * @copyright       2004-2009, Ryan Djurovich
+ * @copyright       2009-2011, Website Baker Org. e.V.
+ * @link			http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.7.0 | 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$ 
+ * @filesource		$HeadURL$
+ * @lastmodified    $Date$
+ *
+ */
+
+header('Location: ../index.php');

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Index: branches/2.8.x/wb/modules/ShowMenu2/upgrade.php
===================================================================
--- branches/2.8.x/wb/modules/ShowMenu2/upgrade.php	(nonexistent)
+++ branches/2.8.x/wb/modules/ShowMenu2/upgrade.php	(revision 2114)
@@ -0,0 +1,21 @@
+<?php
+/**
+ *
+ * @category        modules
+ * @package         show_menu2
+ * @author          Independend-Software-Team
+ * @author          WebsiteBaker Project
+ * @copyright       2004-2009, Ryan Djurovich
+ * @copyright       2009-2011, Website Baker Org. e.V.
+ * @link            http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource      $HeadURL$
+ * @lastmodified    $Date$
+ *
+ */
+
+// Must include code to stop this file being access directly
+if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }

Property changes on: branches/2.8.x/wb/modules/ShowMenu2/upgrade.php
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1,4 ##
+Id
+Revision
+HeadURL
+Date
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
