Hiermenus Go Forth, VI - DHTML Lab | 14 | WebReference

Hiermenus Go Forth, VI - DHTML Lab | 14


Hiermenus Go Forth, VI:
Version 4 - The Page-Specific Parameters (cont'd)


Specifies a JavaScript statement to be evaluated when a menu tree is hidden. All menus trees in the page are affected.

The menu below has a SELECT form element immediately below it. When the menu appears, the form element is hidden. Otherwise, the element would show through the menu. See DHTML Diner for a discussion on form element persistence.

Show the menu and hide the SELECT element

HM_PG_UponHide overrides site-wide global settings declared in the external script.

HM_PG_UponHide can be overruled on a per-tree basis by the evaluate_upon_tree_hide parameter element in top-level menu arrays.

JS statement.
May be specified as:
  • string JS expression to be evaluated

JS expression: "showSelect(true)"
    A custom function that you have created will be called. Unlike function calls used to determine other parameter values, here we expect no return value. We simply execute the function statements when a menu appears.

JS expression: "document.bgColor='white'"
    The background color of the page is changed back to "white" when any menu tree is hidden.

If this parameter is omitted, the relevant Global Parameter value set in the external script is used.

Differences from Version 3 equivalent
There is no Version 3 equivalent. Authors were expected to insert their own code if they needed additional statements executed when a menu tree was hidden.

This parameter should be used in conjunction with HM_PG_UponDisplay, discussed on the previous page.

This concludes our discussion of the Page-Specific Parameters. We are now ready to publish the external script in our next column.

Produced by Peter Belesis and

All Rights Reserved. Legal Notices.
Created: Dec 12, 2000
Revised: Dec 12, 2000

URL: http://www.webreference.com/dhtml/column42/12.html