Add css class on Select box

Add css class on selection box using in CHtml::dropDownList

CHtml::dropDownList(‘name’,‘Selected value’,‘value array’, array(‘default value 1’,‘other any value 2’));

check below example

echo CHtml::dropDownList(‘departure_dropoff_location-’ . $row[‘schedule_id’],$dropoffLocation,


           	array('empty' => '[Select Dropoff Location]','class' => 'departureschedulelocation','disabled'=>'desabled'));

NOTE: Topic moved to proper section (Tips, Snippets and Tutorials instead of Extensions)

Pravin - when posting code, please use the code directive (the <> button on the editor toolbar) so that your code is more readable

NOTE2: you can edit your post to add the code directive ;)