Solved

how to change the color of the text that appears inside a disabled text box

Posted on 2006-07-07
7
238 Views
Last Modified: 2010-05-18
can the text color of a disabled text box be changed to "RED" or any other color??
0
Comment
Question by:ramareddyj
7 Comments
 
LVL 8

Accepted Solution

by:
stmani2005 earned 100 total points
Comment Utility
0
 
LVL 23

Assisted Solution

by:Siva Prasanna Kumar
Siva Prasanna Kumar earned 100 total points
Comment Utility
I think the first suggestion in the below link suits your requirement but yet a good link to refer.

http://www.experts-exchange.com/Web/Web_Languages/HTML/Q_21261155.html

and also check

http://www.thescripts.com/forum/thread98600.html
http://www.codecomments.com/archive298-2004-8-259870.html
0
 
LVL 3

Assisted Solution

by:anumalas
anumalas earned 100 total points
Comment Utility
Hi

please refer the following question its very simple....
using CSS

http://www.experts-exchange.com/Web/Web_Languages/CSS/Q_21891179.html?qid=21891179
0
 
LVL 5

Assisted Solution

by:muktajindal
muktajindal earned 100 total points
Comment Utility
For textbox color change, you can define two separate classes for active and disabled textboxes in your CSS file. Create textboxes with the active class. Whenever you want to disable a textbox, just change the class associated with that textbox. You should get the desired results.
0
 
LVL 4

Assisted Solution

by:Meritor
Meritor earned 100 total points
Comment Utility
If you are using IE then its hard to set color for disabled text box but in Mozilla/Netscape you can write the following code:
input[disabled] {color:red!important;}

As in:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<html>
<head>
<title> New Document </title>
<style type="text/css">
input {
color: green;
}
input[disabled] {color:red!important;}
</style>

</head>

<body>
<form>
<input type="text" disabled value="disabled"></input><br>
<input type="text" value="normal"></input>
</form>
</body>
</html>
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Learn to move / copy / export exchange contacts to iPhone without using any software. Also see the issues in configuration of exchange with iPhone to migrate contacts.
This article will show you how to create an ISO CD-ROM/DVD-ROM image (*.iso), and MD5 checksum signature, for use with VMware vSphere Hypervisor 6.5 (ESXi 6.5). It's a good idea to compare checksums, because many installations fail because of a corr…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

772 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now