I have a mobile friendly web app built using GWT/mGWT. The app has white input text boxes and dark gray input text. However, on Android Browser, the text shows up white-on-white and is thus invisible. All the CSS I tried fails to fix the problem

.my-textBox {
    color: #555 !important;
    background-color: #FFFFFF !important;
    border: 1px solid #A8A8A8;
}
有帮助吗?

解决方案

I am guessing that the colour of the text is being overwritten somewhere else in your stylesheet.

Try being more specific with your rule, such as #container input.my-textBox { ... }

Also, try putting the rule at the very end of your stylesheet and make sure that the stylesheet it's in is the very last stylesheet that's loaded when the browser loads the page.

Finally, make sure there's no inline CSS on the input element itself that's overriding your color rule.

其他提示

why this */ ????

Try

input [type=text]{ 
color: #555;
background-color: #FFFFFF;
border: 1px solid #A8A8A8;
}
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top