[ask] set empty in combo box

hello i have a code:




echo $form->dropDownList($model,'id_advertiser',CHtml::listData(Advertiser::model()->findAll('deleted IS NULL or deleted <> :deleted',array(':deleted'=>1)), 'id', 'name'),

			

				array('onchange'=>'{tes();}')

		);




in my code, I want to set an empty value

I tried like this





echo $form->dropDownList($model,'id_advertiser',CHtml::listData(Advertiser::model()->findAll('deleted IS NULL or deleted <> :deleted',array(':deleted'=>1)), 'id', 'name'),

			array('empty'=>'Please Choose One'),

				array('onchange'=>'{tes();}')//->not run..

		);



but the functions of [the test] does not run

is there a solution?

This should works:


echo $form->dropDownList($model,'id_advertiser',CHtml::listData(Advertiser::model()->findAll('deleted IS NULL or deleted <> :deleted',array(':deleted'=>1)), 'id', 'name'),

                        

                                array('empty'=>'Please Choose One','onchange'=>'{tes();}')

                );



Or eventually:


echo $form->dropDownList($model,'id_advertiser',array_merge(array(''=>'Please select'),CHtml::listData(Advertiser::model()->findAll('deleted IS NULL or deleted <> :deleted',array(':deleted'=>1))), 'id', 'name'),

                        

                                array('onchange'=>'{tes();}')

                );

yeah…

tq Ivica