Color in drop down menu?

liunx

Guest
Hello,<br />
<br />
Is it possible in HTML to use colors for text in a 'drop down menu'? If not, in which language (maybe DHTML) is it possible? <br />
<br />
Thanks in advance.<!--content-->Yes, use CSS for example:<br />
<br />
<style type="text/css"><br />
<!--<br />
select { background-color: red; color: white;}<br />
--><br />
</style><!--content-->Thanks for the reply. But actually that is not what I mean. Is it possible to use several colors for each item of the drop down menu? <br />
<br />
Hope someone can help me. Thanks in advance.<!--content-->This works in IE6<br />
<br />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"<br />
"http://www.w3.org/TR/html4/strict.dtd"><br />
<html><br />
<head><br />
<title>Untitled</title><br />
</head><br />
<body><br />
<div><select><br />
<option style="color: #3300ff;">hello</option><br />
<option style="color: #66ff33;">hello</option><br />
<option style="color: #666666;">hello</option><br />
<option style="color: #ff3333;">hello</option><br />
<option style="color: #669966;">hello</option><br />
</select></div><br />
</body><br />
</html><br />
<br />
And it's CSS, like Rob's solution.<!--content-->Or do you mean each letter different colors?<!--content-->Yes, your code helped me with my problem (to have different colors for each item of the drop down menu). Thanks a lot!<!--content-->
 
Back
Top