Recent Questions Sharepoint Treeview Bind Document Library C
Q: How does one go about changing the parameter or the menu in java script so that a menu selection stays 'on'?
In other words, the menu remains selected, perhaps in a background color that shows the user this menu choice is selected and the user is in the selected menu area.
A: To save your navigation path you should set the following parameter:
var saveNavigationPath = 1;
The menu keeps items highlighted during menu navigation.
0 - disabled, 1 - enabled (default).
You can highlight menu items by default in two ways:
1) Set the pressed item on each page idividually using the following parameter:
var pressedItem = -2;
The toggle mode. Sets an index of an item that will be highlighted by default.
-2 - the toggle mode is disabled;
-1 - the toggle mode is enabled, but no items highlighted by default;0,1,2,3,... - index of highlighted item in a top-level menu.
- delete var pressedItem=1; parameter from your data file
- set correct parameter on each page before you call data file, for example:
<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>
<script type="text/javascript"> var pressedItem=2;</script>
...
<script type="text/javascript" src="menudir/data.js"></script>
2) Set the pressed item/subitem using dm_ext_setPressedItem () function.
Please see more info here:
http://deluxe-menu.com/highlighted-items-sample.htmlQ: How can I set the padding for the menu text at the top for the javascript select menu? I want more padding on the left of the text but I don't want it centered.
A: You can set bigger left padding for your Submenu Style, for example:
var menuStyles = [
["menuBackColor=transparent","menuBorderWidth=0","itemSpacing=1","itemPadding=0px 5px 0px 25px"],
];
itemPadding=0px 5px 0px 25px - top right bottom leftQ: I ran IE7 and now the "Incorrect Copyright" message appears again on the menu. Please advise.
A: What version of JavaScript Tree Menu you're using now?
JavaScript Tree Menu v2.0 works fine in IE.
If you're using older version you should upgrade you JavaScript Tree Menu to v2.0, please, visit thefollowing page. You can find all info about the upgrade here:
http://deluxe-menu.com/rq-css-vertical-menu-v2.0-support.html.
Q: I am having a problem creating a submenu. I did not get any js errors but nothing happens.
What I have found is that even when I have dynamic=1;
I was getting an error saying object expected so I added the dmenu_dyn.js manually (i.e. <scripttype="text/javascript"src="../../Javascript/menu/dmenu_dyn.js"></script>) but now get no errors but no submenu is created.
Do I have to add all the js files in the menu folder manually as I thought it was just
<scripttype="text/javascript"src="../../Javascript/menu/dmenu.js"></script>
that was needed.
All, I am trying to add a submenu under the challenge topmenu.
function addChallengeItems(){
dm_ext_createSubmenu(0, 0, 3, ['Buy JavaScript Tree Menu Now!', "order-deluxe-menu-purchase.html", "", "", "Buy JavaScript Tree Menu Now!", "_blank"]);
}
And then a href that calls addChallengeItems()
<ahref="javascript:addChallengeItems();">add</a>
A: There is no need to add all engine files into your menu folder.
You can add only
dmenu.js
dmenu_dyn.js
More info about Description of Files you can find here:
http://deluxe-menu.com/description-of-files-info.html
Please delete also the following line from your code
<script type="text/javascript"src="../../Javascript/menu/dmenu_dyn.js"></script>
Try that.