clickcolor does not seem to be working for me??

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
ShawnO
Super Advanced
Super Advanced
Posts: 35
Joined: Wed Aug 11, 2004 9:34 pm

clickcolor does not seem to be working for me??

Post by ShawnO »

I am trying to get the clickcolor function to work with my menu's and even though it is specified, the maintain their onbgcolor and offbgcolor, oncolor, offcolor settings. The site is not available from the outside, so I will post some snippets of code below. All I would like to happen is that when someone has visited a link, the menu item changes to the standard purple-ish colour.

Code: Select all

_menuOpenDelay=50;
_menuCloseDelay=1500;
var subFore = '#FFFFFF';
var subBack = '#005596';
var subForeOn = '#FFFFFF';
var subBackOn = '#4F8EB6';
var fW = 'bold';
var fS = '10px';
var mP = '1';
var topvar = 'top=bTop;';
_subOffsetTop=0;              // Sub menu top offset
_subOffsetLeft=0;            // Sub menu left offset
var bTop=getObj('milMenu').offsetTop+28;
var bLeft ='offset=-296';
with(menuStyle=new mm_style()){clickcolor='#FF0000';clickbgcolor='#05596';onbgcolor=subBackOn;oncolor=subForeOn;offbgcolor=subBack;offcolor=subFore;bordercolor='#296488';borderstyle='solid';borderwidth=1;separatorcolor='#2D729D';separatorsize='1';padding=mP;fontsize=fS;fontstyle='normal';fontweight=fW;fontfamily='Verdana, Tahoma, Arial';headercolor='#000000';headerbgcolor='#ffffff';subimage='/siteTemplate/images/arrow.gif';subimagepadding='2';}
with(mainMenu=new mm_style()){clickcolor='#FF0000';clickbgcolor='#05596';oncolor='#000000';offcolor='#FFFFFF';bordercolor='#296488';borderstyle='solid';borderwidth=0;separatorcolor='#2D729D';separatorsize='0';padding=5;fontsize='10px';fontstyle='normal';fontweight='bold';fontfamily='Verdana, Arial, Helvetica, sans-serif';headercolor='#000000';headerbgcolor='#ffffff';subimage='/siteTemplate/images/arrow.gif';subimagepadding='2';}
Thanks!
Shawn
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

I put your 'mainMenu' code in the milonic download menu_data.js file version 5.691 , and substituted mainMenu for the menuStyle in all the menus and it works in IE5.5, Netscape7, Firebird [fox] .07, Opera 7.11

Code: Select all

with(mainMenu=new mm_style()){
clickcolor='#FF0000';
clickbgcolor='#005596';
oncolor='#000000';
offcolor='#FFFFFF';
bordercolor='#296488';
borderstyle="solid";
borderwidth=0;
separatorcolor='#2D729D';
separatorsize=0;
padding=5;
fontsize='10px';
fontstyle='normal';
fontweight='bold';
fontfamily='Verdana, Arial, Helvetica, sans-serif';
headercolor='#000000';
headerbgcolor='#ffffff';
subimage='arrow.gif';
subimagepadding=2;
} 
I couldn't test the other one because I don't know what the var stuff is.

Ruth
ShawnO
Super Advanced
Super Advanced
Posts: 35
Joined: Wed Aug 11, 2004 9:34 pm

Post by ShawnO »

Thanks for the reply Ruth. I tinkered around a bit and got the colour to work.

Thanks!!

Shawn
Post Reply