over and out filter on submenu only?

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
kerryreilly@yahoo.com
Beginner
Beginner
Posts: 1
Joined: Fri Aug 06, 2004 4:29 pm

over and out filter on submenu only?

Post by kerryreilly@yahoo.com »

Can anyone help me to apply over and out filters on sub menus, not the main menu? I tried just moves those two lines into each submenu function, but doesn't seem to have worked...
Thanks in advance...
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

I don't know what your style code is, but you could do this. Create another style using copy of, which is a very short method for a second style. But, in that copy of style you also include the over and out filter which you have left out of the main style. For example we'll assume mainstyle as your main style name and substyle as the other style:

Code: Select all

with(mainstyle=new mm_style()){ 
onbgcolor="#000000"; 
oncolor="#ffffff"; 
offbgcolor="#ffffff"; 
offcolor="#FF0000"; 
bordercolor="#FF0000"; 
borderstyle="solid"; 
borderwidth=1; 
and so on for everything else you have here;} 
Then in your copy of you would put this

Code: Select all

subStyle=new copyOf(mainstyle); 
subStyle.overfilter=whatever you want for it; 
subStyle.outfilter=whatever you want for it; 
The substyle you just wrote goes after the complete end of the mainstyle, after the closing }

Having done that you need to just make sure you put substyle as the style for the submenus. It will be exactly the same as the mainstyle, using the same colors, fonts whatever you have listed in the mainstyle but will also have the over and out filters. If you're not sure about using copy of method, then you could just copy and paste your main style rename it and add the over and out filter options you want. Hope that helps.

Ruth
Post Reply