Faisal,

Why you want to use image, you can use stylesheet. You may refer following 
code:

<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<STYLE type="text/css">
OPTION.mar{background-color:maroon; color:white}
OPTION.red{background-color:red; color:maroon}
OPTION.blue{background-color:blue; color:maroon}
</STYLE>

</HEAD>

<BODY>
<select name="obj" style="width:100">
<option value="">Select</option>
<option value="M" class="mar">&nbsp;</option>
<option value="B" class="red">&nbsp;</option>
<option value="R" class="blue">&nbsp;</option>
</select>
</BODY>
</HTML>


Sunil




Faisal Mahmoud <[EMAIL PROTECTED]> 
10/20/2005 12:31 AM
Please respond to
"Struts Users Mailing List" <[email protected]>


To
Struts Users Mailing List <[email protected]>
cc

Subject
Adding images to <option> items in a <select> drop down list






Hi,

I am creating a drop down list using the HTML <select> and <option>
tags. The items in the list will be color names (ex. red, green, blue,
etc..). I would like a small square image to be next to each color
name text in the list. How would I go about this in my jsp file with
my struts tags?

-Faisal

--
http://www.quidprocode.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Reply via email to