Reply LinkBack Thread Tools Search this Thread
Old 03-11-2006, 13:21   #1 (permalink)
mtran
Nooneknow
 
mtran's Avatar
 
Join Date: Nov 2004
Location: CA, USA
Posts: 38
disabled element not grayed out in IE

I'm new to javascript, and recently trying to validate a form. When using "disabled" IE doesn't gray out the disabled field while FF grays it out, as in below. How to make it work in IE?

Code:
document.formName.fieldName.disabled = true;
  Reply With Quote
Old 03-11-2006, 16:02   #2 (permalink)
funkyprem
For all your goober needs
 
funkyprem's Avatar
 
Join Date: Dec 2004
Location: Coventry, UK
Posts: 1,531
this is just a guess, but shouldn't it be

document.formName.fieldName.disabled.value = disabled;

like I say I could well be talking out of my arse.
__________________
Time is really the only capital that any human being has, and the one thing that he can’t afford to lose. - Thomas Edison

prem ghinde
  Reply With Quote
Old 03-11-2006, 19:56   #3 (permalink)
stickmus
hmmm...
 
stickmus's Avatar
 
Join Date: Jan 2004
Location: Yorkuk
Posts: 2,127
Quote:
Originally Posted by funkyprem
like I say I could well be talking out of my arse.

That you are.

As far as I know the only visual indication in a text field is a greying of the text, so an empty field will look exactly the same. Give it a class at the same time and you'll be able to style it differently.
__________________
George Smith - a vain attempt to get higher on google for my name

  Reply With Quote
Old 03-11-2006, 19:57   #4 (permalink)
stickmus
hmmm...
 
stickmus's Avatar
 
Join Date: Jan 2004
Location: Yorkuk
Posts: 2,127
__________________
George Smith - a vain attempt to get higher on google for my name

  Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search


Contact Us - Web Design Forums - Archive - Top
Search Engine Optimization by vBSEO 3.0.0 RC8