How to show image for the drop down list? have tried a few alternative but dont work. Thanks

 <tr>
                                <td class="label"><label for="kelas">Kelas:</label></td>
                                <td class="field">

<select id="kelas" name="kelas"  >
<option value="Pilih kelas" selected="selected"></option>
<option value="1 Tekal" >1 Tekal</option>
<option value="1 Tekad" >1 Tekad</option>
<option value="1 Tekun" >1 Tekun</option>
<option value="1 Tabah" >1 Tabah</option>
<option value="2 Tekal" >2 Tekal</option>
<option value="2 Tekad" >2 Tekad</option>
<option value="2 Tekun" >2 Tekun</option>
<option value="2 Tabah" >2 Tabah</option>
<option value="3 Tekal" >3 Tekal</option>
<option value="3 Tekad" >3 Tekad</option>
<option value="3 Tekun" >3 Tekun</option>
<option value="3 Tabah" >3 Tabah</option>
<option value="4 Tekal" >4 Tekal</option>
<option value="4 Tekad" >4 Tekad</option>
<option value="4 Tekun" >4 Tekun</option>
<option value="4 Tabah" >4 Tabah</option>
<option value="5 Tekal" >5 Tekal</option>
<option value="5 Tekad" >5 Tekad</option>
<option value="5 Tekun" >5 Tekun</option>
<option value="5 Tabah" >5 Tabah</option>
<option value="6 Tekal" >6 Tekal</option>
<option value="6 Tekad" >6 Tekad</option>
<option value="6 Tekun" >6 Tekun</option>
<option value="6 Tabah" >6 Tabah</option>
</select>
                            </tr>

`

Recommended Answers

All 6 Replies

Member Avatar for diafol

You need to clarify what you need. Do you mean an image in every dropdown item? If so, this won't be php, but js. I recently used a cool plugin called ddSlick:

http://designwithpc.com/Plugins/ddSlick

Although setup can be a pain.

You want to show a different image depending on which item is selected from the drop down list? Do I understand you correctly?

Member Avatar for diafol

You want to show a different image depending on which item is selected from the drop down list?

Bit unclear isn't it? C'mon joey, give us more info.

@Glider Pilot: yes..different imahe appear when selection is make on the drop down list
@diafol: sorry for the unclear description...

Member Avatar for LastMitch

@joeyliew7

yes..different imahe appear when selection is make on the drop down list

Ok, since you have the dropdown list. When someone pick a option from the list then where does the image appears? You didn't provide how the images will echo out or how it will appear. Having a dropdown list doesn't really help here. You have to explain what is the issue with your drop down list. That's what Glider Pilot & diafol been trying to ask you.

thank you all for the helps. appreciate it..

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.