spacer
Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / experts / dhtml / column38
Developer News
News Flash: Adobe Has iPhone Workaround
Adobe's Flash 10.1 Goes Mobile (Minus iPhone)
A Salute to Visionary CEOs

Logo

Hiermenus Go Forth, III:
Version 4 - The External Arrays - Menu and Item Parameters


As published in Column 35, here is a comparison of the old Version 3 and new Version 4 child menu array structures:

Version 3Version 4
arMenu1_1 = new Array(

    item_display_text,
    item_link_url,
    item_has_child,

    item_display_text,
    item_link_url,
    item_has_child,

    ...
)
HM_Array1_1 = [

[],

[item_display_text,
 item_link_url,
 item_is_rollover,
 item_permanently_highlighted,
 item_has_child],

[item_display_text,
 item_link_url, 
 item_is_rollover,
 item_permanently_highlighted,
 item_has_child],

 ...
]

Real-world child-menu arrays with valid values look like this:

Version 3Version 4
arMenu1_1 = new Array(

"3-D","http://www.webref.com/3d/",0,
"Design","http://www.webref.com/dlab/",0,
"DHTML","http://www.webref.com/dhtml/",1,
"JavaScript","http://www.webref.com/js/",0

)
HM_Array1_1 = [
[],

["3-D","http://www.webref.com/3d/",1,0,0],
["Design","http://www.webref.com/dlab/",1,0,0],
["DHTML","http://www.webref.com/dhtml/",1,0,1],
["JavaScript","http://www.webref.com/js/",1,0,0]

]

As in the top-level menu arrays, all elements of child-menu arrays are themselves arrays. The first element is an empty array ([]). It is reserved for menu-specific parameters that we may add in future versions. These parameters will affect only the menu defined by the array. Presently, there are no such parameters. In the future, they may include parameters to define a particular width or color scheme on a menu-by-menu basis, for example.

It is too early in the development of Version 4 to include such specific parameters. What will be included will be based on your feedback after Version 4.0 is released.

For now, all child-menu arrays will have an empty array as a first element, and menu look will be defined on a global or tree level only.

Version 4 does, however, introduce powerful item-specific parameters.

Produced by Peter Belesis and

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Reprints, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Building a Banking Application Home Page with OOP · Mixing Scripting Languages · Review: phpFox, a Social Networking CMS with all the Bells and Whistles
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Enterprise 2.0: Social Networking in the Cloud · BroadSoft Marketplace Hastens Pace of Telephony Innovation · Review: HTC Hero for Sprint

All Rights Reserved. Legal Notices.
Created: Oct 03, 2000
Revised: Oct 03, 2000

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