Recent Questions
Q: I've begun experimenting with the dhtml rollover menu program and like what I see.
Question, when I have a tree menu on the left and the user clicks a node, I want the resulting HTML page to appear next to the dhtml rollover menu, on the right hand side. How do I reposition the HTML page so it doesn't take up the whole page and cover the menu?
A: You can use frames and open link pages into the content frame, or use Iframe.
Please, set the name for your iframe, for example:
<iframe name ='myFrame' ...
<frame name ='myFrame' ...
And then you must set the following dhtml rollover menu parameter in the data file withyour menu:
var titemTarget="myFrame";
Q: I have already tried this exact same method, using and alternate "itemBackColor" and this is not what I needed. As you can see in your example putting in an item back color only give you a different bg color on the item itself, but the BG of the menu around it remains the same. In your example the lighter bg color of my menu is surrounding the item bg color making this look more like a mistake and poor design.
It do use the item bg color for the rollover in my menu, as you can see, but implementing this does not give me what I need. I need the BG color behind this item to be completely flush with the sides of the menu.
I had already checked the menu system thoroughly before contacting you and I was well aware of the option.. but as you can see this is not the solution. It is very important to me that this looks perfect, and what I need is not built into this menu by default.. I need another solution.
A: You should set the following parameter:
var itemSpacing=0;
You can also try to paste separators between items.
Q: I'm trying the deluxe menu and I'm positively impressed.
But now I'm trying to simply use javascript to add some properties to my menu.
I modified the dynamic to 1
and I get only one error in the javascript monitor telling me:
Error: dm has no properties
Source File:
http://devel.discgolf-geneve.ch:8081/docroot/dg/js/menu/data.files/dmenu_dyn.js
Line: 8
A: Please, see how you should write this function:
function dm_ext_addItem (menuInd, submenuInd, iParams)
<script type="text/javascript" language="JavaScript1.2">
dm_ext_addItem(0, 0, ["Hello", "testlink.htm", "", "", "Hello", "_blank", "-1"]);
menuInd - index of a menu on a page, >= 0. (you have written menuInd=1, but if you have one menu on your page you should write 0).
You also have written itemStyleInd=1, but you have only one style in your menu. So you should write "0" or "-1".
Q: What I would like to see is the ability to have a base site navigation menu with all the definitional entries (size, locations, icons, etc.) defined but all the menuitems be called from an Ajax file.
A: You cannot use ajax submenus for the top items.
But you can use several .js file, for example:
params.js //file with all menu parameters (size, locations, icons, etc.)
all code before
var menuItems = [
...
];
dm_init();
data_ajax1.js //data files for ajax submenus
data_ajax2.js
data_ajax3.js
...
main_data.js - data file with the following code:
var menuItems = [
["Item 1","", "", "", "", "", "0", "0", "data_ajax1.js", "", "", ],
["Item 2","", "", "", "", "", "0", "0", "data_ajax2.js", "", "", ],
["Item 3","", "", "", "", "", "0", "0", "data_ajax3.js", "", "", ],
["Item 4","", "", "", "", "", "0", "0", "data_ajax4.js", "", "", ],
];
dm_init();
You can also place this code into your html page directly (in the place where you want tohave a menu):
<script type="text/javascript">
var menuItems = [
["Item 1","", "", "", "", "", "0", "0", "data_ajax1.js", "", "", ],
["Item 2","", "", "", "", "", "0", "0", "data_ajax2.js", "", "", ],
["Item 3","", "", "", "", "", "0", "0", "data_ajax3.js", "", "", ],
["Item 4","", "", "", "", "", "0", "0", "data_ajax4.js", "", "", ],
];
dm_init();