Hi everybody
i’m having trouble with this piece of code:
<?php $this->widget('bootstrap.widgets.TbGridView',array(
'id'=>'prodotti-grid',
'dataProvider'=>$model->search(),
'type'=>'striped bordered condensed',
'template'=>'{summary}{pager}{items}{pager}',
'columns'=>array(
'codice',
'nome',
'descrizioneBreve',
array('name'=>'schedaTecnica',
'htmlOptions'=>array('width'=>'540'),
'type'=>'html',
'value'=>function($data){
$CHtmlPurifier = new CHtmlPurifier();
$CHtmlPurifier->options = array('HTML.AllowedElements' => array());
$purified = $CHtmlPurifier->purify($data->schedaTecnica);
return '<div style="overflow:hidden; height:200px;">' . $purified . '</div>';
}
),
[cut]
the problem is in this line:
return ‘<div style=“overflow:hidden; height:200px;”>’ . $purified . ‘</div>’;
some css rules are not applied at all (like overflow:hidden) but the height rule is applied succesfully
No errors are thrown
what can be the cause?
Thanks in advance
p.s. i solved by using rules in a css file, but i’m still wondering why using inline css doesn’t work…