Recent Questions
Q: Hi, I was wondering if there is a way to leave a main java swing menu bar item highlighted when in that section. For example if I clicked on "Contact Us" and when I am on the contact us page, the "Contact us" navigation would still be highlighted. I appreciate any help you might have, thanks!
A: The java swing menu bar has only two states normal and mouseover. We'll try to add the pressed state in the future.
You can set a pressed item using Javascript API:
function dm_ext_setPressedItem (menuInd, submenuInd, itemInd, recursion)
Sets a current pressed item.
menuInd - index of a menu on a page, >= 0.
submenuInd - index of a submenu, >= 0.
itemInd - index of an java swing menu bar item, >=0.
recursion = true/false - highlight parent items.
But notice, to use dm_ext_setPressedItem() you should know ID of selected item and subitem. You can't get this ID after you reload your page. That is why you should write your own code on PHP.
Q: I have a new poblem. The submenus of my dropdown menu php are going up instead of down.
A: You should set the following parameter:
var subMenuVAlign="top";
Q: Where can I change the state of Vista1 buttons?
A: If you want to have 1 state button, please, go to "Edit IndividualStyle"/Item Styles. Click on the style "Top Item" and in bothitemBackImage fields you should write btn_black.gif.
So in your data file you will have such code:
var itemStyles = [
["itemWidth=92px","itemBackColor=transparent,transparent", "fontStyle=normal 11px Tahoma","fontColor=#FFFFFF,#FFFFFF", "itemBackImage=btn_black.gif,btn_black.gif"],
];
Q: Things are mostly working great. I want my menu to appear centered at the top the page. Here's the code:
<table style="text-align: left; width: 100%;" border="0" cellpadding="2"cellspacing="2">
<tbody>
<tr>
<td style="width: 100%; text-align: center;"><script type="text/javascript" src="navbar.js"></script>
</td>
</tr>
</tbody>
</table>
The table appears at the far left edge of the window. I tried with both absolute (x=20, y=10) and relative (both x and y unset) coordinates. Help!
A: If you want to center the menu paste itwithin the <div > or <table> with a static position and specify a center alignment for it, for example:
<DIV align=center>
<SCRIPT src="data/data.js" type=text/javascript>
</SCRIPT>
</DIV>
<table width=800>
<tr>
<td align=center width=600> </tr>
</table>
Please, set exact value for var menuWidth parameter, for example:
var menuWidth = "600px";
This can help to align your menu correctly in all browsers.
Try also to specify units in "px".
Set also:
var absolutePos = 0;