Recent Questions Java Swing Merge Trees
Q: How does one go about changing the parameter or the JavaScript so that a vertical menu selection stays 'on'? In other words, the vertical 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.html
Q: In the navigation bar below (done in Spanish) I am trying to display the word “Niños” (Children) but looks like this special character is not displayed correctly. How I fix this?
A: Try to write it in the following way:“Niños”
Q: I'm trying to position my menus inside absolutely positioned <DIV> tags. If the <DIV> tag has style="position:absolute; top:100px; left:50px;" in the actual tag, deluxe-menu seems to work correctly. If I have the "position:absolute; top:100px; left:50px;" in a <STYLE> tag or a linked stylesheet and applied using id or class selectors, then deluxe-menu does not work correctly: sub menus have a 100pixel offset in the y direction and a 50 pixel offset in the x direction. This is with no change to the .js data file (I have absolutePos=0;) Is this a known issue, and is it planned to be fixed?
A: See, the problem is that the script can't get css properties of the object if they are described in separate .css block (or file).
In other words, you can't get the value of "position" attribute of the object if the object doesn't have this property within inline style(style="position:absolute"). To get the value you should move .css style into style="" attribute.
Please, try to add your
css file -> inline css, for example:
For example, you should add style="position:absolute;"
to the
<DIV id=head>
So, you'll have:
<DIV id=head style="position:absolute;">
Now we have only such solution for this problem.
We'll try to fix this problem in the future versions.
Q: I cannot see the arrow.gif's in my rollover drop down menu.
Here is my code:
var arrowImageMain=["menudir/arrow_main3.gif","menudir/arrow_main3.gif"];
var arrowWidthSub=0;
var arrowHeightSub=0;
var arrowImageSub=["menudir/arrow_sub5.gif","menudir/arrow_sub4.gif"];
Do I need to put the arrow's somewhere else?
A: You should check the following parameter:
var pathPrefix_img="data-samples/images/";
Please check that you have the correct path to your aroows relative to the folder withindex.html file.
For example, you have:
menudir/
menu.js
dmenu.js
arrow_main3.gif
...
index.html
In menu.js file you should write:
var pathPrefix_img="menudir/";
var arrowImageMain=["arrow_main3.gif","arrow_main3.gif"];
var arrowImageSub=["arrow_sub5.gif","arrow_sub4.gif"];
or
var pathPrefix_img="";
var arrowImageMain=["menudir/arrow_main3.gif","menudir/arrow_main3.gif"];
var arrowImageSub=["menudir/arrow_sub5.gif","menudir/arrow_sub4.gif"];