Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:26

Menu Item Text Color changing once visited


Poster: wpfeiffe
Dated: Tuesday June 1 2004 - 15:57:17 BST

Is there a property that can be turned on or off that will prevent currently visited menu item text from changing color. I have the menu style in a javascript file and am writing out the menu data via a JSP tag that looks at our security model. The menu is being built fine and is displayed correctly but once menu items are selected the text color changes to black. Here are the style definitions:


_menuCloseDelay=500 // The time delay for menus to remain visible on mouse out
_menuOpenDelay=250 // The time delay before menus open on mouse over
_subOffsetTop=0 // Sub menu top offset
_subOffsetLeft=0 // Sub menu left offset

with(AFRootStyle=new mm_style())
{
offcolor="white";
offbgcolor="#006633";
oncolor="black";
onbgcolor="#99cc99";
bordercolor="#000000";
fontsize="11";
fontstyle="normal";
fontweight="bold";
fontfamily="sans-serif,Arial";
padding=5;
subimage="../../resources/images/mm_arrowdn.gif";
separatorcolor="black";
separatorsize="1";
headercolor="#ffffff";
headerbgcolor="#000099";
subimagepadding="5";
overfilter="Fade(duration=0.5);Alpha(opacity=90);Shadow(color='#777777', Direction=135, Strength=5)";
outfilter="randomdissolve(duration=0.3)";
borderstyle="solid";
borderwidth=1;
pagecolor="black";
openonclick="true";
}

with(AFMainStyle=new mm_style())
{
offcolor="white";
offbgcolor="#006633";
oncolor="black";
onbgcolor="#99cc99";
bordercolor="#000000";
fontsize="11";
fontstyle="normal";
fontweight="bold";
fontfamily="sans-serif,Arial";
padding=5;
subimage="../../resources/images/mm_arrow.gif";
separatorcolor="black";
separatorsize="1";
headercolor="#ffffff";
headerbgcolor="#000099";
subimagepadding="5";
overfilter="Fade(duration=0.5);Alpha(opacity=90);Shadow(color='#777777', Direction=135, Strength=5)";
outfilter="randomdissolve(duration=0.3)";
borderstyle="solid";
borderwidth=1;
pagecolor="black";
openonclick="true";
}

Any help is greatly appreciated.


Poster: John
Dated: Tuesday June 1 2004 - 16:47:38 BST

The color changes to black because you told it to!
Code:
oncolor="black";


Possibly some reading would be in order - http://www.milonic.com/forum/viewtopic.php?t=2981. :)


Poster: wpfeiffe
Dated: Tuesday June 1 2004 - 17:46:02 BST

The text color changing to black is fine when the user is mousing over the item to select it. The problem is that the style never changes back to the off color. From the moment the item is selected the text color changes to black and is not changing back to white. If I take onColor out of the menu style, won't the rollover effect go away?


Poster: Ruth
Dated: Tuesday June 1 2004 - 18:00:10 BST

Do you have a style sheet? Do you have a:visited color set or something in the a: link set?

Ruth


Poster: wpfeiffe
Dated: Tuesday June 1 2004 - 18:09:20 BST

Yes. There is a a:link and a:visited style. What should we do to prevent this from interferring with the menu? Do we need to take these out all together?

Thanks for the helpful response.


Poster: Ruth
Dated: Tuesday June 1 2004 - 18:35:35 BST

What I did on my pages was to eliminate all but the a:hover and a:active. That gave me what I wanted on the page but stopped doing the visited link color change in the menu. I'm not sure if there's a way to set the a:visited so it doesn't affect the menu since the menu reads the css. I'll try some things and see if any work.

Ruth