Border color query

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
pat
Beginner
Beginner
Posts: 3
Joined: Mon Nov 29, 2004 9:29 pm

Border color query

Post by pat »

I want a colored border (on all sides) of the entire menu (not individual menu items). But for current page menu item, I want the white right border and white background. How can this be done.

Thanks in advance.
Last edited by pat on Tue Nov 30, 2004 4:19 pm, edited 1 time in total.
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

Sounds like a trip to the quick ref guides is in order... :D

Use onborder= and offborder= with the same shorthand used for CSS...

Code: Select all

onborder="1px solid #ffffff";
etc.
John
pat
Beginner
Beginner
Posts: 3
Joined: Mon Nov 29, 2004 9:29 pm

Post by pat »

Thanks.

But I need the onborder only on the right side. There should be no borders on top, bottom and left sides. How can this be done?
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

You can do it using the offclass and onclass parameters to create the border. If you have a css style sheet you can create the border class for the menu in it and then in your global style call it along with the other styles listed. For example, in the style sheet you might have the following two definitions [one is for the default border style when no mouse is over it, that would be a border all around, the other is for when you mouseover just having a border on the right side:

Code: Select all

.menuborder {border:1px solid #ffffff}
.menuborderOn {border-top:0px solid #ffffff;border-right:1px solid #ffffff;border-bottom: 0px solid #ffffff;border-left:0px solid #ffffff}
Then in the menu_data.js file you would put this along with all your other style codes in the top section where you have the onbgcolor, offbgcolor etc.

Code: Select all

offclass="menuborder"; 
onclass="menuborderOn";
Ruth
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

You could also try the rawcss= property...

Code: Select all

rawcss="border-right:1px solid #ffffff";
etc.
John
pat
Beginner
Beginner
Posts: 3
Joined: Mon Nov 29, 2004 9:29 pm

Post by pat »

Thanks for your suggestions.

I need another solution to the following problem.

I want a colored border (on all sides) of the entire menu (not individual menu items). But when a menu item is highlighted with (pagebgcolor= white), I want the right border color of that menu item to be white. How can this be done.

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 »

There is a style property called pageborder which can be coded as pageborder="1px solid #ffffff"; I have no idea if that could be set up as a 'class' and be able to set it for just having a border on the right side.
I don't know what your menu is like, but you have a number of options to use for the page property, i.e. pagebgcolor, pagebgimage, pageborder, pageclass, pagecolor, pageimage. You can find an explanation of each of them on the menu quick reference guides - style properties. [there's a link below to that. I'll try and see if I can figure something out to get what you want and post back here if I can.

Ruth
Post Reply