473,394 Members | 1,960 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,394 software developers and data experts.

change secekted color in drop-down list

Hi!

is it possible to change "selector" color in drop-down list?

<select name="select" style="background-color: #ff0000">
<option style="background-color: #ff0000" value="1">Cony</option>
<option style="background-color: #ffffff" value="2">Alex</option>
<option style="background-color: #0000ff" value="3">Peter</option>
</select>

backgroung is no problem, but I want to change that gray defoult color
that apears when you "mark" f ex Alex. hoppe you understand what I
mean...
Jul 20 '05 #1
2 21325
carramba wrote:
Hi!

is it possible to change "selector" color in drop-down list?

<select name="select" style="background-color: #ff0000">
<option style="background-color: #ff0000" value="1">Cony</option>
<option style="background-color: #ffffff" value="2">Alex</option>
<option style="background-color: #0000ff" value="3">Peter</option>
</select>

backgroung is no problem, but I want to change that gray defoult color
that apears when you "mark" f ex Alex. hoppe you understand what I
mean...

carramba,

Apparently there is no way, at least not on Netscape 7.1 or IE 5.5.
What I tried was:

<style>
option:focus {background-color: green !important}
option:active {background-color: green !important}
option:hover {background-color: green !important}
</style>

none of which had any effect. (By the way, on my system, the selection
hovered over became white text on a dark blue background, in both
browsers. Once selected, it took on the attributes on the select tag.
At no time did I see anything gray.)

That's not a bug, however, as the CSS2 spec provides a loophole:

"CSS doesn't define which elements may be in the above states, or how
the states are entered and left."
(http://www.w3.org/TR/REC-CSS2/select...pseudo-classes)

Chris Beall

Jul 20 '05 #2
Chris Beall <Ch*********@prodigy.net> wrote in message news:<Cu******************@newssvr15.news.prodigy. com>...
carramba wrote:
Hi!

is it possible to change "selector" color in drop-down list?

<select name="select" style="background-color: #ff0000">
<option style="background-color: #ff0000" value="1">Cony</option>
<option style="background-color: #ffffff" value="2">Alex</option>
<option style="background-color: #0000ff" value="3">Peter</option>
</select>

backgroung is no problem, but I want to change that gray defoult color
that apears when you "mark" f ex Alex. hoppe you understand what I
mean...

carramba,

Apparently there is no way, at least not on Netscape 7.1 or IE 5.5.
What I tried was:

<style>
option:focus {background-color: green !important}
option:active {background-color: green !important}
option:hover {background-color: green !important}
</style>

none of which had any effect. (By the way, on my system, the selection
hovered over became white text on a dark blue background, in both
browsers. Once selected, it took on the attributes on the select tag.
At no time did I see anything gray.)

That's not a bug, however, as the CSS2 spec provides a loophole:

"CSS doesn't define which elements may be in the above states, or how
the states are entered and left."
(http://www.w3.org/TR/REC-CSS2/select...pseudo-classes)

Chris Beall


thanx , it didn't have eny effect on my system too.. but thanx any way!
Jul 20 '05 #3

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

Similar topics

1
by: Paul McGuire | last post by:
***This is of especial interest for those who are using the pyparsing module, and have defined grammars that make use of CaselessLiteral.*** One of the bugfix requests I recently got for...
6
by: Dave C. | last post by:
Hello, I have created the following trigger: CREATE TRIGGER tr_UDFTest ON UserDefinedFields FOR INSERT, UPDATE AS DECLARE @foobar varchar(100) SELECT @foobar= foobar FROM inserted IF (...
1
by: sherkozmo | last post by:
I have my SQL 7.0 server set for Mixed security. I see now (finally) the advantages of having windows authentication security for windows groups. I do most of my developing in Access Projects...
1
by: Alexandre Flament | last post by:
I would like to know what change on textarea : - when user change content with keyboard - when user drag/drop some text to textarea By what change, I mean for example, this kind of event : - at...
3
by: Trevor Best | last post by:
Is there a *simple* way to change a collumn from allowing null to not null? I just unchecked "allow nulls" in EM and the SQL it generates to do this one thing is astonishing, create table, drop...
11
by: SarahMarsden | last post by:
I'm new to Dreamweaver (using MX 2004). I have a 2 row 3 column table. I have set each column to 200 pixels. The second row I have merged into one cell. When I enter text (or anything else) into...
5
by: Robert Stearns | last post by:
Either I missed something, or ALTER TABLE does not have this capability. Is there any way of doing it except DROPping all constraints which mention this table, EXPORTing the data, DROPping the...
7
by: Markus McGee | last post by:
Hi all, I have a quick question...I believe. On my web page, call it page A, I have a drop downlist with runat server enabled. When the drop downlist change event occurs it repopulates a...
6
by: Aaron Smith | last post by:
Ok. I have a dataset that has multiple tables in it. In one of the child tables, I have a column that I added to the DataSet (Not in the DataSource). This column does not need to be stored in the...
4
by: Michael Hannon | last post by:
Greetings. We're running Postgres 7.3 on an Intel linux box (Redhat Enterprise server, version 3.0). We find ourselves in an awkward position: we have a database of attributes relating to...
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: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.