Recent Questions
Q: I was wondering if there is a way to disable links in the dhtml context menu on a page.
A: To disable your menu items you should set the following parameter to disable all items:
var itemTarget="_";
Or you can disable items individually.
["Home","testlink.html", "", "", "", "_", "", "", "", "", "", ], //disabled
["Product Info","", "", "", "", "", "", "", "", "", "", ],
["|Features","testlink.html", "", "", "", "_", "", "", "", "", "", ], //disabled
["|Installation","", "", "", "", "", "", "", "", "", "", ],
You can also use function dm_ext_changeItem (menuInd, submenuInd, itemInd, iParams)
function to disable items on-the-fly, for example:
dm_ext_changeItem (0, 2, 3, ["", "", "", "", "", "_", "", "", ""]);
Q: It's simply not saving the state. Clicking the items on the menu is inconsistent. Sometimes it saves sometimes not.
It seems to be a lot worse in this area.
A: See, Tree Menu saves it's state using cookies.
But it can't re-save the same cookie file from different folders.
For example, if the tree from "website/page.html" saves it's state,the menu from "website/content2/page.html" can't read this state andit creates it's own state. The problem is that it's a standardfeature of browsers and Javascript can't control that.
Q: Thank you for your reply. I have run the example sent by you. Your dhtml menu example has horizontal menus and it hides all the menus.
But I am using xp vertical menu. In that I have Home,Sales,Customer Support,Reports,Access Control menus.
For Admin login I need all the menus including submenus.
But for employee login i need Home , Sales, Customer Support menus and i need only few sub menus only.
Please help me with this issue.
A: You can try to use API functions in that case:
function dm_ext_changeItemVisibility (menuInd, submenuInd, itemInd, visibility)
More info:
http://www.deluxe-menu.com/functions-info.html
Q: Is it possible to add a combo box or a search field to a tree view component?
A: You can paste any html code inside item's text, for example:
["+Support", "", "icon5_t.gif", "icon5_to.gif", "", "Support Tip"],
["|Index <select style='width:120px;height:17px;font:normal 10px Tahoma,Arial;'><option>Section 1<option>Section 2<option>Section 3</select>","", "", "", "", "", "", "0"],
["|Search <input type=text style='width:80px;height:17px;font:normal 10px Tahoma,Arial;'> <input type=button value='Go'style='width:30px;height:17px;font:normal 10px Tahoma,Arial;'>", "", "", "", "", "", "", "0"],
["|Write Us", "mailto:[email protected]", ""],
["|<INPUT TYPE=checkbox CHECKED ID=chk1 onclick='choosebox1()'>Uncheck this check box for some free advice","","","",],
["<img src='img/sep.gif' width=113 height=1>"],