Menu (R)
Username:  
Password:
  > Home
> User Guide
> Reference
> Portal Object
v Development Guide
    o Overview
    v A Typical Page (C)
       o Prelude
       o Head
       v Body
          o Menu (R)
          o Login (F)
          o Admin Only (F)
          o Settings (F)
    > Data Handling
    > Applications
    > Working BEE


Shortcuts
sys Class
debug Class
Intrinsic Conversions
>> Development Guide >> A Typical Page (C) >> Body >> Menu (R) <=  =>      <  1  2  >  
doMenu Parameters Menu bar

There are three control parameters and several level parameters (one for each level).

The first control parameter is "menuOffTimeout", which is the number of milliseconds the menu stay on the screen after the mouse cursor has moved out.  If is default is 100, but you may increase it to, say, 300 if you find the submenu disappear too soon for you to reach the next level.

The second control parameter is "menuIndicator", which contains a string to indicator a next level submenu.  It is generally an image of an arrow.

The third control parameter is "root", which indicates the root item of the submenu to display.  The default is the root of the menu tree.  This "root" parameter is useful if you have several submenus that is needed to display in different areas of the webpage.  For example, a top menu bar and a side menu bar.

In the previous example, two levels have been defined.  You can extend it to 4 levels by defining L4, and include L4=(var)L4 to the "doMenu" command.  (Most menus have maximum 4 levels, for if you have more than 4, the menu will become very messy.)

The menu is produced as multiple tables, each represents a menu or submenu.  When the page starts, all submenus are hidden and only the top menu are show.  A submenu will show up when the mouse cursor moves over its parent item.

The clickable links on the menu are called "item".  The collection of items on the same bar or drop-down is called, guess what, "menu".

The elements of the level variable (L1 and L2 etc) are properties of the menu object, and most of them control the attributes and positioning of the hidden tables.

Please be aware that in the top level (L1) of a HorizontalDrop menu, each item is a TD and they all join up horizontally to a TR.

Starting from the second level (L2 onwards), the menu is vertical and each item is in fact a TR, with two TDs in it.  The first one (on the left) is for the item link and the second one is the submenu indicator (e.g. a '>' or an arrow image).

For a VerticalSweep menu, the top level is in the same format as the second level and onwards.  So L1 of HorizontalDrop menu is the odd one out.  We call it HDL1.

Here is a run down of the elements and their meanings:

  • itemattr: Attributes for the TD tag of the item
  • itemwidth: The width in pixel of the item
  • itemheight: The height in pixel of the item
  • itemseparator: A string preceeding each item except for the first one
  • itembegin: The TD tag before the item TD (right after the TR for non-HDL1)
  • itemend: The TD Tag after the item TD (right before the TR for non-HDL1)
  • offsetleft: The pixel distance between the first possible menu of the level and the left edge of the page
  • offsettop: The pixel distance between the first possible menu of the level and the top edge of the page
  • embossleft: The TD attributes of the left edge of the menu
  • embossright: The TD attributes of the right edge of the menu
  • embosstop: The TD attributes of the top edge of the menu
  • embossbottom: The TD attributes of the bottom edge of the menu
  • menuattr: Attributes of the TABLE tag for the menu table
  • menubegin: A constant item before the first one (TD for HDL1 and TR for the rest)
  • menuend: A constant item after the last one (TD for HDL1 and TR for the rest)
  • namebegin: A string preceding the item name (but within the clickable link)
  • nameend: A string following the item name (but within the clickable link)
  • position: "absolute" (default) or "relative".  It is used to indicate whether the offsetleft and offsettop standard for the distance to the page edge (absolute) or to the edge of the construct it is in (relative).

The "position" element is usually used only in L1 when the menu bar is encapsulated in another construct (e.g. within another TD of the webpage).

The "offsetleft" and "offsettop" elements are usually for L1 only.  The offsets for L2 onwards are usually set to 0 as they are floating depending on the parent item's location.  If you do not define L1:position = "relative", you'll have an absolute positioned top level menu.  In that case, you will need to fine tune L1:offsetleft and L1:offsettop to fit it in accordingly.

Previous Page       Next Page

Accsoft Computer Technology Pty Ltd     ABN: 98 065 617 549
PO Box 892, Epping NSW 1710         Level 1, Epping Office Park, 242 Beecroft Rd, Epping NSW 2121, Australia
Tel: Sydney - (02)98691668     National - 1300-881668         Fax: (02)98691866
© Copyright 2003 Accsoft Computer Technology Pty Ltd