Dropdownlist Pictures

Hello,

I have managed to create a multilingual site by following

yiiframework.com/wiki/208/how-to-use-an-application-behavior-to-maintain-runtime-configuration/

this wonderful wiki and I wish to improve the design of the site by adding country flags to the drop down list used for choosing the language.

This is what I hope to do:

binnyva.blogspot.com/2006/01/icons-for-select-menu-options-in.html

However, the comments on the page indicate that the suggested solution works only in Firefox. I went through the W3C website to see if there is a simple ‘img’ paramter or something like that which I can add to the htmlOptions of the CHtml::Dropdownlist, but there does not appear to be a way that easy. I could not find anything in the Yii documentation, wikis or extensions, either.

Of course, it is far from being fatal if there is no easy cross-browser way to achieve this, but it would be a nice touch.

The only cross-browser way is by building your own dropdown, for example with Select2 (extension).

That seems doable.

Thanks for your time. :)