Hiermenus Go Forth, V - DHTML Lab | 3 | WebReference

Hiermenus Go Forth, V - DHTML Lab | 3


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


Sets the border width for all menus in the page. All menus, in all cascades (top-level and children) are affected.

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

May be specified as:
  • integer
  • string
  • string JS expression to be evaluated

Example Values
integer: 2
    All menu borders in the page will be two pixels wide.

string: "3"
    All menu borders in the page will be three pixels wide.

JS expression: "getBorderWidth()"
    A custom function that you have created will be called. The return value of this function will be the HM_PG_BorderWidth parameter, and all menus in the page will comply.

JS expression: "(IE4 ? 5 : 2)"
    The complete JS code is included in the parameter declaration. In the above example, HM_PG_BorderWidth will be 5 if the browser used is Internet Explorer, and 2 if it is not. Setting a different border width for IE is useful when HM_PG_BorderStyle is set to a value other than "solid." (see Comments below)

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

Differences from Version 3 equivalent
The borWid parameter in Version 3:
  • accepted only integer values.
  • was mandatory.

The HM_PG_BorderStyle parameter may be given a variety of values, but only IE will recognize them. Navigator will always render a border as "solid". If you choose a "double" border style, for example, it will not render correctly if HM_PG_BorderWidth is set to a value less than 3 and a solid border in NS that is 3 pixels wide might not look elegant. Therefore, you will need to give HM_PG_BorderWidth a conditional value as in the JS expression example above.

Next, HM_PG_BorderColor.

Produced by Peter Belesis and

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

URL: http://www.webreference.com/dhtml/column41/2.html