473,387 Members | 1,624 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

grey-out/disabled item in listbox

Hi,

Is there such thing that an item in the listbox is disabled and is
appeared grey-out?

How can I implement this in html/javascript?

Thanks
A
Mar 11 '06 #1
5 13557
acord wrote:

Is there such thing that an item in the listbox is disabled and is
appeared grey-out?

I assume you mean a <select> element?
To disable an option add the "disabled" attribute. It does not change
the color but does prevent the mouseover and click from having any affect.
To change the color as well, add a style, "option.disable" for instance,
that sets the colors.

--
jmm (hyphen) list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Mar 11 '06 #2
Jim Moe wrote:
acord wrote:
Is there such thing that an item in the listbox is disabled and is
appeared grey-out?


I assume you mean a <select> element?
To disable an option add the "disabled" attribute. It does not change
the color but does prevent the mouseover and click from having any affect.
To change the color as well, add a style, "option.disable" for instance,
that sets the colors.

Hi, this only work with firefox, but I can't get it to work under IE6.

thanks
A
Mar 11 '06 #3
acord wrote:
Is there such thing that an item in the listbox is disabled and is
appeared grey-out?


I assume you mean a <select> element?
To disable an option add the "disabled" attribute. It does not change
the color but does prevent the mouseover and click from having any affect.
To change the color as well, add a style, "option.disable" for instance,
that sets the colors.

Hi, this only work with firefox, but I can't get it to work under IE6.

URL showing a test case?

--
jmm (hyphen) list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Mar 11 '06 #4
Jim Moe wrote:
acord wrote:
Is there such thing that an item in the listbox is disabled and is
appeared grey-out?

I assume you mean a <select> element?
To disable an option add the "disabled" attribute. It does not change
the color but does prevent the mouseover and click from having any affect.
To change the color as well, add a style, "option.disable" for instance,
that sets the colors.


Hi, this only work with firefox, but I can't get it to work under IE6.


URL showing a test case?


need to use optgroup in this case.

A
Mar 11 '06 #5
acord wrote :
Jim Moe wrote:
acord wrote:
Is there such thing that an item in the listbox is disabled and is
appeared grey-out?


I assume you mean a <select> element?
To disable an option add the "disabled" attribute. It does not change
the color but does prevent the mouseover and click from having any
affect.
To change the color as well, add a style, "option.disable" for instance,
that sets the colors.

Hi, this only work with firefox, but I can't get it to work under IE6.

thanks
A


This has been reported in several pages of the wiki feedback pages on
MSIE 6 and MSIE 7. We're just like yourself, asking, waiting, expecting,
hoping that IE 8 will implement and support disabled for <option>.

"HTML 4 Support and spec violations
disabled attribute for option"
http://channel9.msdn.com/wiki/defaul...andardsSupport

"MSIE 6 and below do not support setting a specific option to be
disabled. Is this also fixed as part of the reworking of the select
element?"
http://blogs.msdn.com/ie/archive/200...76.aspx#514183
"When will Microsoft finally reach full support for HTML 4.01?
(...)
- label and disabled attributes for option and optgroup"
http://blogs.msdn.com/dmassy/archive...62.aspx#529968

"IE8 planning is already underway, and we appreciate the valuable
feedback we've been receiving on what we should be working on, as well
as the feedback we've received on IE7." Eric Law from Microsoft
http://blogs.msdn.com/ie/archive/200...76.aspx#515659
"Wow, congrats, you guys are finally where you should have been 7 years
ago. Quote from KunCong above
'Disable of OPTION is in the list of possible improvement in future IE
release.' "
http://blogs.msdn.com/ie/archive/200...76.aspx#522116

For MSIE 6, you can set the text color of the option node to gray as a
workaround.

Gérard
--
remove blah to email me
Mar 15 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Isabelle | last post by:
Hey, How do you feel about using grey text for copy? I love grey for its neutral presence and ability to downplay something and give a clear and crisp look to the overall design of a site but...
3
by: Jacques Chaurette | last post by:
Hello all , thanks in advance for any help. While looking for a solution to how to replace the grey box while an applet loads, a search of Google got me an article by Glenn s. Peffers that claims to...
0
by: Sérgio Almeida | last post by:
Greetings Is it possible to change the color of a combobox (combobox arrow button), instead of grey? If so, how?? Thanks Sérgio
5
by: Peter Verijke | last post by:
Hi, I have a possible framework bug. Sometimes when i call other code by double clikking the datagrid, i get on returning a grey colored cell over the active cell, still showing the old data....
2
by: Jeff Jarrell | last post by:
The thin grey line that goes across the editor to mark off the sub\functions\regions from one another, is there a way to turn it off? I was considering using an underscore for my private member...
10
by: Andrew Kidd | last post by:
I see this when I'm stepping through in the debugger ... just thought I'd ask, and I just know it's going to be one of those "Doh" moments, but it's got me foxed just now.
2
by: SpankyTClown | last post by:
When I set an objects data enabled property, the form displays these objects in grey. Is there any way to change the colour? Thanks
1
by: David J | last post by:
Application does open, to a grey screen, but not access to database. 5mb of data exists, Explorer tells me so. I encountered a similar problem at work with Excel not so long ago, which was...
1
by: joe3dge | last post by:
I tried making a game ing java and it complies fine but when i view it it just shows a grey box with a red x. i looked online and found the this is caused by a bad plug-in but all other applets work...
4
by: marfola | last post by:
I'm trying to implement bottom-to-top vertical text using CSS attributes in IE : writing-mode: tb-rl; filter: flipv fliph; But I have encountered the following: the text is...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.