Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


change different text color when read only or not editable

Posted on 2006-06-19
Medium Priority
Last Modified: 2006-11-18

I have web pages when they are in un-editable or read only mode; the text box, check box/radio box, select box etc... are in default dim color (light grey) and users complaint that they are hard to read.  

How am I going to change the fore-ground color?

Many Thanks,
Diane Ha

Question by:tnova1
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
LVL 30

Expert Comment

ID: 16934792
Firefox supports colors on disabled form elements, but IE and Opera don't.
AFAIK, there is no way you can change that.
You can tell the complaining users that they can use firefox.

<input type="text" disabled style="background: #EEE; color: black;" value="hello">
<input type="button" disabled style="background: #EEE; color: black;" value="hello">

Author Comment

ID: 16935247
I cann't force them to use Firefox, these controls was .net web controls, otherwise I can use the readonly mode.

But I change the Background color. It does make them more clear and readable now.

Author Comment

ID: 16935346
You can't change the fore-color but you can change the background color for disable controls in IE.
LVL 30

Accepted Solution

GrandSchtroumpf earned 1000 total points
ID: 16935955
> otherwise I can use the readonly mode.
Yes, but that's only for text inputs.

> You can't change the fore-color but you can change the background color for disable controls in IE.
I noticed that while testing.  It's better than nothing i guess.

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When writing CSS, there are a few simple rules that will make your life easier.    1. Using ‘* {box-sizing:border-box;}’. Using this will wrap all your elements in a nice little compact box-model that will give you the width you want, like so... …
Why do we like using grid based layouts in website design? Let's look at the live examples of websites and compare them to grid based WordPress themes.
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.
Suggested Courses

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question