Home > Article > Backend Development > Yii Framework Development Tutorial Zii Component-Droppable Example ._PHP Tutorial
We modify the above example and add a Droppable area. When a UI component is dragged and dropped into this area, "Dropped" is displayed.
[php]
01.beginWidget('zii.widgets.jui.CJuiDroppable', array(
02. 'options'=>array(
03. 'drop'=>'js:function(event,ui){$(this).html("Dropped!")}',
04. ),
05. 'htmlOptions'=>array(
06. 'style'=>'width: 300px; height: 300px; padding:
07. 5px; border: 1px solid #e3e3e3; background: #f7f7f7',
08. ),
09. ));
10.echo 'Drop here';
11.
12.$this->endWidget();
13.?>