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:52
CSS Properties
Poster: joejoeE
Dated: Monday February 28 2005 - 21:11:49 GMT
I'm trying to use CSS properties instead of the javascript styles and I'm having some troubles. On the main site, it says..
Quote:
Please note that not all properties can be declared but the vast majority should be fine.
Certainly, someone knows more about using CSS with milonic and could share their knowledge. Is there anything more accurate than this that would list what properties do what within the menus? I'm partly being lazy but I don't want to try every single CSS property to figure what works.
Kind regards.
Poster: Ruth
Dated: Tuesday March 1 2005 - 0:50:04 GMT
I can give you some:
border properties, margin, padding, background-color, font properties, text-align; width [it seems to apply to the item] in the horizontal the menu would be the width + padding + margin x number of items, in the vertical the menu would be the width listed plus padding right and left. Height functions the same way, it's itemheight, which in horizontal would be the menu height unless you actually specify one and in vertical the menu height would be the height + padding + margin x number of items.
That's all I remember right now. You need to create an off and an on class if you want to keep the sense of mouseOver changes. Hope that helps some.
example:
Code:
.mainOff {
background-color:#fafcff;
color:#468C8C;
border-top: 1px #CC99CC inset; border-right:3px #CC3399 inset;border-bottom:3px #CC3399 inset; border-left:1px #CC99CC inset;
font-size: 11px;
font-style: normal;
font-weight: normal;
font-family: arial,helvetica,"times new roman";
text-align: left;
width:110px;
height:50px;
text-decoration: underline overline;
padding:5px;
margin: 2px;
}
.mainOn {
background-color:#468C8C;
color:#fafcff;
border-top: 1px #CCFF66 outset; border-right:3px #339900 outset;border-bottom:3px #339900 outset; border-left:1px #CCFF66 outset;
font-size: 11px;
font-style: normal;
font-weight: bold;
font-family: arial,helvetica,"times new roman";
text-align: right;
width:110px;
text-decoration: line-through;
padding:2px;
margin: 3px;
}
background-color:#fafcff;
color:#468C8C;
border-top: 1px #CC99CC inset; border-right:3px #CC3399 inset;border-bottom:3px #CC3399 inset; border-left:1px #CC99CC inset;
font-size: 11px;
font-style: normal;
font-weight: normal;
font-family: arial,helvetica,"times new roman";
text-align: left;
width:110px;
height:50px;
text-decoration: underline overline;
padding:5px;
margin: 2px;
}
.mainOn {
background-color:#468C8C;
color:#fafcff;
border-top: 1px #CCFF66 outset; border-right:3px #339900 outset;border-bottom:3px #339900 outset; border-left:1px #CCFF66 outset;
font-size: 11px;
font-style: normal;
font-weight: bold;
font-family: arial,helvetica,"times new roman";
text-align: right;
width:110px;
text-decoration: line-through;
padding:2px;
margin: 3px;
}
I put mine in the head of the document, but it will work from a stylesheet. In the menu data file you'd put this in the style definition in place of whatever you have in the css style offclass="mainOff"; onclass="main-on";
background-image doesn't seem to work. Perhaps because it needs to know if it's an bgimage, which would place it in an item as background, or in a menubgimage.
Ruth