Dropdownlist With Icons

Because the option-tag of a select allows no tags, this should be a css (or jquery solution).

I have tried with the options tag and css, but I can’t get it to work.

 //generated options

 <option value="option1" class="icon-list">Option1</option>


css like


    background-position: <img src='http://www.yiiframework.com/forum/public/style_emoticons/default/huh.gif' class='bbc_emoticon' alt='???' />?;

    background-image: url("img/icon-list.png");


Is there an extension for a dropdownlist with icon support base on a jquery plugin?


Ok, thanks - looks nice.

But seems that I have to implement a Yii wrappper extension by myself…

Joblo, could you share your wrapper for ddslick?

grab any dropdown list code, and set icons in background using background property

I have used multipleselectbox to show bootstrap icons instead.


Menubuilder EMBBootstrapIconProvider