Go Back   Velocity Reviews > Newsgroups > HTML
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

HTML - change background-color

 
Thread Tools Search this Thread
Old 05-22-2006, 02:40 PM   #1
Default change background-color


Hi,

I need to change background-color of input when disabled is set to
disabled. I already 've tryed

input[disabled="disabled"] {
background-color:#333333;
color:#FF0000;
}

but it's doesn't work

any idea ?



alexjaquet@gmail.com
  Reply With Quote
Old 05-22-2006, 03:23 PM   #2
Jonathan N. Little
 
Posts: n/a
Default Re: change background-color

wrote:
> Hi,
>
> I need to change background-color of input when disabled is set to
> disabled. I already 've tryed
>
> input[disabled="disabled"] {
> background-color:#333333;
> color:#FF0000;
> }
>
> but it's doesn't work
>
> any idea ?
>


Most modern browsers already do this internally, the old ones that don't
also don't support the CSS require to 'trap' the condition....

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
  Reply With Quote
Old 05-24-2006, 02:01 PM   #3
alexjaquet@gmail.com
 
Posts: n/a
Default Re: change background-color

Thks Jonatan but it's doesn't work with IE 6 or 7. I've tryed to
hardcode
document.select_wish.category.style.color = 'green';

but it's doesn't work to,

this work under Firefox :
input[disabled="disabled"] {
background-color:#333333;
color:#FF0000;
} or

document.select_wish.category.style.color = 'green';

  Reply With Quote
Old 05-24-2006, 02:32 PM   #4
Jonathan N. Little
 
Posts: n/a
Default Re: change background-color

wrote:
> Thks Jonatan but it's doesn't work with IE 6 or 7. I've tryed to
> hardcode
> document.select_wish.category.style.color = 'green';
>
> but it's doesn't work to,
>
> this work under Firefox :
> input[disabled="disabled"] {
> background-color:#333333;
> color:#FF0000;
> } or
>
> document.select_wish.category.style.color = 'green';
>

Do to IE's incomplete support of CSS and CSS selectors, but my point was
that modern browsers now support disable form elements and internally
'dim' the visual appearance of the disabled control. Why do you feel the
need to micromanage the disabled appearance? I know it varies by OS, but
why would you want to change what the visitor is familiar with and
recognizes as "disabled"?

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
  Reply With Quote
Old 05-24-2006, 03:06 PM   #5
alexjaquet@gmail.com
 
Posts: n/a
Default Re: change background-color

Hi Jonathan ,

In fact I want to change style properties for the visibility, I use
input fields in my website
like here :
http://avant-garde.no-ip.biz/cgi-bin...article=779 0

  Reply With Quote
Old 05-24-2006, 03:50 PM   #6
Jonathan N. Little
 
Posts: n/a
Default Re: change background-color

1) Please quote what you are referring to, when using a newsreader we do
not see the previous message in the same window link the webpage Google
Groups produces

wrote:
> Hi Jonathan ,
>
> In fact I want to change style properties for the visibility, I use
> input fields in my website
> like here :
> http://avant-garde.no-ip.biz/cgi-bin...article=779 0
>


The above link produces no output, not even a response header!

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump