Recent Questions
Q: May I can use PHP code in menu items of my dhtml website navigation menu?
A: You may generate a menu from a database or XML using any server-side script, e.g., PHP, ASP, VB, etc.
However, these scripts don't work inside of Javascript .js files, so, you should move parameters of a menu from a .js file into an html-page, e.g.:
<!-- Deluxe Menu -->
<noscript><a href="http://deluxe-menu.com">Javascript Menu by Deluxe-Menu.com</a></noscript>
<script type="text/javascript"> var dmWorkPath = "menudir/";</script>
<script type="text/javascript" src="menudir/dmenu.js"></script>
<!-- (c) 2006, http://deluxe-menu.com -->
<script type="text/javascript" language="JavaScript1.2">
// and describe parameters of a menu
var parameter1=value1;
var parameter2=value2;
etc.
var menuItems = [
// here you generate items using server-side scripts (php, asp, vb, etc.)
];
</script>
The example of the menu working with PHP/MYSQL you can find here:
http://deluxe-menu.com/rq-loading-bar-MySQL-support.html
Q: How do I center a menu item inthe drop down menu example?
A: Try to use the following parameter:
var itemAlignTop="center";Q: I can't find anywhere in your documentation that states where
I can call function onclick other than in the menu target for dhtml menu script.
A: You can use onclick event in the following way:
var menuitems = [
["<div onClick='getLink(\'/Admin/Sales/Customers/Customers.asp\')'>Table of Contents</div>", ""]
];
Q: I have to find out, how the tree view navigation is NOT expanding in the beginning..
A: You should set the following parameter:
var texpanded=0;
Use + signs before items text to expand the some items:
["+Land","", "", "", "", "", "", "0", "", "", ],