I have a menu with one "root" item. I see the use of the "+" symbol within the item name. I do not see any documentation regarding this symbol, only "|". Can you explain?
If I have one menu with this one "root" node, how would I add an subitem to this root node?
Here is my code so far, but the inserted items appear to be at the same level as the root node.
var rootItem = dtreet_ext_getItemIDByIndex ( 0,0 );
var menuItem = new Array(10);
for ( var i = 0; i < producers.length; i++ )
var producer = producers[ i ];
menuItem = producer.name;
dtreet_ext_insertItem ( 0, 0, i + 1, menuItem );
A: See dtreet_ext_insertItem () function has the following parameters:
function dtreet_ext_insertItem (menuInd, parentItemID, itemInd, itemParams)
Creates a new item and inserts it into a specified position.
parentItemID - ID property of an item.<, >= 0.
itemParams - item parameters.
Notice that parentItemID is the Id property of the parent item (notindex). If you want to add top items you should set parentItemID=0.
itemInd - you should use this parameter if you want to add item in thespecific place, for example set itemInd=5 if you want to add itembefore the existing item with itemInd=5.
If you set itemInd=null the new item will be added at the end of this submenu and its index will be added automatically.
Q: In our application we want to have the drop down menu configured inside IFrame but still visible on the page. Currently the menu slides down inside the iframe,
Is this scenario configurable.
All they can to do with <IFrame> is to loadpages into it.
Q: I want that this tree expanded or collapsed (clicking on the image. e.g. like the right button) and go to the link when clicked on the item.
A: No problem.
You can assign a link to the item that has subitems.
When you'll click on item's button, it'll be expanded.
When you'll click on the item, item's link will be opened.
Q: Is there a way to increase the margin between the text on the main tree menu and the edge of the dhtml menu control. The text appears to be right up against the left margin.
A: You can add symbol before item's text, for example:
or you can write:
Actually you can use any html code within dhtml menu control items.