|
|
May I can use PHP code in menu items of my down menu button?
Return to Recent Questions
Q:
May I can use PHP code in menu items of my down menu button?
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">down menu button 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
Return to Recent Questions
Related:
- March 15, 2009 - How can I disable items in javascript onmouseover menu?
- March 21, 2009 - I am trying to get my submenu to be all black in my menu popup...
- March 28, 2009 - How do I get started with this down menu button?
- March 30, 2009 - Is there a way to optimize the horizontal menu using to reduce the loading time for submenus?
- March 31, 2009 - Is there any way can we display submenu items on mouse over in web navigation bar?
- Apr 01, 2009 - How can I set different parameters for diferent items in my mouse over drop down menu?
- Apr 03, 2009 - I would like to change the height of the submenu items in the vertical dropdown menu...
- Apr 04, 2009 - Is there a way to have an automatic line-break for large submenu items in menue script?
- Apr 06, 2009 - I am trying to use the site navigation in a perl script.
- Apr 06, 2009 - Can the link items NOT open a new window in the menu popup?
- Apr 11, 2009 - I cannot see the shadow on the top items in my drop down menu example.
|