Is It possible?
Tried this but all i see is blank haha

while (rs.next()) 
{
String c=rs.getString("ProductID");
String d=rs.getString("ProductName");
String e=rs.getString ("ProductImage");
out.print("<option value="+c+"><img border=0 src=\"picture/" + e + "\" width = \"170\" height=\"157\"></option>");
}

ANy one with recommendations on how to make a picutre based drop down list

Recommended Answers

All 6 Replies

Hi Dreamer,

It is possible to set an image as a background for an <option>.

Using CSS, you can set the style of the <option> like width, height, color, background-image, etc.., But IE fails to support this, it simply shows the text. If you view in Mozilla, it works fine.

Try it once. Its Obviously possible.
Check in the following site
http://www.cssplay.co.uk/menus/image_dropdown.html

I tried viewing it in FireFox still doesnt work

I'm not sure what Firefox you using, but my one is up-to-date and I have no problem to see this effect. It is not exactly the programmable drop down as you tried to do but it does the job

After trying various ways i found alternative =p thanks for the help =)

Well if you found alternative why don't you share with others?

sure
i put it in a
<div style="overflow: auto; width: 780px; height: 530px;">

</div>

thus it is still equally neat.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.