(c) 2016, Deluxe-Menu.com
Ctrl+F2 - enter/switch menu | Arrow keys - navigate | Esc - exit menu  
  About Us
  Recent Questions


    How would I get the index of the item in the html dropdown menu?

Return to Recent Questions

Q: > You should call the following function:
> dtreet_ext_getItemIDByIndex (0, 12)
> where 12 - is index of the item.

How would I know that 12 is the index of the item? How is itemInd different from its itemID? I assume the menuInd is always 0 for the first menu (or only in my case) menu on a page?

A: Yes, menuInd is the number of the menu on your page (in your case menuInd=0).

itemInd is the number of the item in your menuItems, for example:

var tmenuItems =
["Home", "http://deluxe-tree.com", "icon1_t.gif", "icon1_to.gif","", "Home Page Tip","_blank"],//itemInd=0

["<img src='data_files/images/sep.gif' width=113 height=1>"],//itemInd=1

["+What's New<br><span id='letter'>This is pretty cool. I need to buy this deluxe menu</span>", "", "icon2_t.gif", "icon2_to.gif", "", "Product Info Tip"],//itemInd=2
["|What's New", "testlink.htm", ""], //itemInd=3
["|Features", "testlink.htm", ""], //itemInd=4
["|Installation", "testlink.htm", ""], //itemInd=5
["|Functions", "testlink.htm", ""], //itemInd=6
["|Supported Browsers", "testlink.htm", ""], //itemInd=7
["Samples", "", "icon3_t.gif", "icon3_to.gif", "", "Samples Tip"], //itemInd=8
["|Sample 1", "testlink.htm", ""], //itemInd=9
["|Sample 2", "testlink.htm", ""], //itemInd=10
["|Sample 3", "", ""], //itemInd=11
["||New Sample 1", "testlink.htm", ""],//itemInd=12
["||New Sample 2", "testlink.htm", ""],//itemInd=13

Return to Recent Questions

Bootstrap Radio Set Bootstrap Menu Responsive  |  Bootstrap Offset Usage  |  Bootstrap Checkbox Label  |  Bootstrap Sidebar Dropdown  |  Bootstrap Columns Mobile  | 
Copyright (c) 2019, Deluxe-Menu.com
Home  |  Product Info  |  Samples  |  Download  |  Purchase  |  FAQ  |  Site Map  |  Terms of Use  |  Write Us
All rights reserved. html website maker | bootstrap navbar | bootstrap popup window | easyhtml5video.com | wowslider.com