RichFaces - Background for Input Fields
I played around a long time to found out to avoid RichFaces to set a background color for all input fields.
If you are using your own Skin all Input Fields will appear with a background image. This image has a "color-fading" effect. The effect can be general controlled by the following contxt-parameter in the web.xml file:
<context-param>
<param-name>org.richfaces.CONTROL_SKINNING</param-name>
<param-value>enable</param-value>
</context-param>
The image is generated by RichFaces from the skin property 'additionalBackgroundColor'. So my first thought was to set this attribute to 'FFFFFF'. After that each input field apears without the background. But a side effect of this change is that also all menues have no more mouse-over effect - every menue entry is now white (FFFFFF) :-(
So it is no good idea to change the skin Attribute 'additionalBackgroundColor' to white!
So my solutions was to override the css definition of the input files using a custom css file like this:
textarea, textarea[type="textarea"], input[type="text"], input[type="password"], select {
background-color:#FFFFFF;
background-image: none;
border-color: silver;
}
It works fine for me and all input fields appear now with white background and a silver border.
Posted at 02:28PM Jan 22, 2009
Posted by: Ralph
Category: General