Page 1 of 1
HTML Style Question
Posted: December 7, 2006, 2:25 pm
by Sylvus
I can't for the life of me find out how to change the font color on a disabled text input to look black. I know that you can change the color via the style attribute in the input tag, but setting it to black still looks light gray, by virtue of it being disabled. I have to imagine I'm just missing some sort of "background-tint" element or something.
Anyone have a good solution? For now I'm just using td's and making them look like an input field, but I'd like to actually use disabled inputs.
Thanks
Posted: December 7, 2006, 2:41 pm
by cadalano
can you use the read only prop instead?
i would just use a div or something, though. why do you need them to be an input box? aesthetics?
Posted: December 7, 2006, 4:03 pm
by cadalano
btw- MSDN is the best HTML reference out there. If there is a simple style tag to solve the problem- it will be listed there (i found nothing). Its a fantastic place to have bookmarked
http://msdn.microsoft.com/library/defau ... ements.asp
Posted: December 7, 2006, 4:37 pm
by lmnt9
Code: Select all
input {
font-family: Verdana, Arial;
font-size: 10px;
color: #000000;
}
This works in firefox 1.5.0.8, but not in IE v6. I don't have 7 to test. Maybe an IE limitation?
Posted: December 7, 2006, 4:50 pm
by lmnt9
Seems like IE wont accept a font color change, but you can change the background color...
Posted: December 7, 2006, 5:24 pm
by Sylvus
Yeah, I was looking for font color change. Currently IE 6 is the main standard we have to code for, so for now I just avoided using disabled input boxes.
That wasn't my choice in the first place, one of the analysts wanted it to look like that. Oh well.