Gerard10
(Gerard Verhaag)
March 25, 2014, 10:12am
1
Hi,
I’m trying to modify the background color of my menubar with the following css:
.v-menubar-mainmenu {
background-color: white;
font-family: "Lucida Sans",Georgia,Serif;
font-size: large;
border: 5px solid white;
}
Within my code the style is set like:
menubar.setStyleName("mainmenu");
But the background color is not changing to white, while the font-size and border color and border thickness are set according to the css code as presented above!
Anybody any idea what I’m doing wrong here?
Regards,
Gerard
Felype
(Felype Ferreira)
March 28, 2014, 9:21am
2
Try changing background instead of background-color.
.v-menubar-mainmenu {
background: white;
font-family: “Lucida Sans”,Georgia,Serif;
font-size: large;
border: 5px solid white;
}
Marko1
(Marko Grönroos)
March 28, 2014, 10:31am
3
Hi,
Often when a CSS rule fails to apply, there’s a problem with cascading, usually with the specificity of the rule. See the
CSS intro in the Book here
.
You can usually see the problem easily with FireBug or some other HTML inspector for your browser.
Could be something else as well.