Recent Questions Datatable And Treeview Yui Together
Q: I have images that I want to use for the top level of the menu. How do I create a menu using images that were created in a different program? I tried to look in the frequently asked questions but IcouldnТt find anything that told me how. Thank you in advance for your help.
A: You can use any image for the top items.
You can set
var itemBackImage=["",""];
Or, create Individual style
var itemStyles = [
["itemWidth=92px","itemBorderWidth=0","fontStyle=normal 11px Tahoma","fontColor=#FFFFFF,#FFFFFF","itemBackImage=data-vista-03.files/btn_magentablack.gif,data-vista-03.files/btn_magenta.gif"],
];
The new method of making image-based menus: if item text is empty, icon fields will be used as item images.
For example:
["", "index.html", "itemImageNormal.gif", "itemImageOver.gif", "Home Page"]
Q: How can I declare the "delay" time for the opening js popup window?
A: You should set the following parameter:
openAfter:20,
Open after time (secs).
Q: Greetings. How do I make a menu item as default selected and open when the page loads with the dhtml menu bar script? Thanks.
A: JavaScript Tree Menu has only two states normal and mouseover.
Try to do the following things:
- delete var pressedItem=1; parameter from your data file
- set correct parameter on each page before you call data file, forexample:
<noscript><a href="http://deluxe-menu.com">dhtml menu bar script by Deluxe-Menu.com</a></noscript>
<script type="text/javascript"> var dmWorkPath = "menudir/";</script>
<script type="text/javascript" src="menudir/dmenu.js"></script>
<script type="text/javascript"> var pressedItem=3;</script>
...
<script type="text/javascript" src="menudir/data.js"></script>
You can also set a pressed item using Javascript API:
function dm_ext_setPressedItem (menuInd, submenuInd, itemInd, recursion)
Sets a current pressed item.
menuInd - index of a dhtml menu bar script on a page, >= 0.
submenuInd - index of a submenu, >= 0.
itemInd - index of an item, >=0.
recursion = true/false - highlight parent items.
But notice, to use dm_ext_setPressedItem() you should know ID of selected item and subitem. You can't get this ID after you reload your page. That is why you should write your own code on PHP.
Q: On my website I am a total of 2 menus being generated. How do I correctly generate "SE-Friendly Code" if I have 2 menu in javascripts? The "DM Links" code that is being generated will have a few of the same dm id because the menus are created seperate. How do I get it so each menu will have different dm id with no overlaps?
A: The identifiers in these links are additional parameters.
<div id="dmlinks" style="font:undefined;color:#000000;text-decoration:none">
<a id="dmI0" href="testlink.html">Home</a>
<a id="dmI2" href="testlink.html">Features</a>
<a id="dmI4" href="testlink.html">Description of Files</a>
You can delete these identifiers or leave them.
So, if you have several menu in javascripts on the same page you should generate twoblocks of search engine friendly code and add them on your page.