|
|
I am looking for a way to dynamically affect the contents of menu javascripts..
Return to Recent Questions
Q:
I recently purchased DeluxeMenu for a project I'm working on and a new
requirement has been submitted. I am looking for a way to dynamically affect
the contents of menu javascripts after it's been rendered(displayed) in the browser.
Can this be accomplished with this component?
A:
1) You can use API functions to affect items dynamically:
http://deluxe-menu.com/functions-info.html
2) Generate your menu items dynamically from database.
Unfortunately we don't have working example with ASP.
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) 2008, 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:
- Sep 22, 2006 - Where do I add my "blahblah.htm" page links in js menu?
- Oct 19, 2006 - I want a javascript toolbar with all the buttons the same length.
- Nov 17, 2006 - Is there a way to change preview screen color of the onmouseover menu maker?
- Dec 03, 2006 - We have several problems with your javascript side menu. Please, help!
- Dec 21, 2006 - Can I install and run this pull down menu html on a server running OS X?
- Jan 07, 2007 - I can't install my javascript mouseover menu on the page made with Yahoo sitebuilder
- Jan 25, 2007 - Is there a way to use smartscrolling function on the MAIN javascript sliding menu?
- Feb 09, 2007 - Is there a way to center cool css buttons names because they are left justified?
- Feb 26, 2007 - Does your dhtml treeview support right to left languages, like Hebrew?
- March 13, 2007 - My drop down menu scripts don't work with a popup.
- March 31, 2007 - My mainmenu items are not links. So I need no link cursor in css slide menu.
|