D
D
des1roer2015-04-30 08:38:43
Yii
des1roer, 2015-04-30 08:38:43

Yii TbGridView\Cgridview table width?

you need to change the width of the entire TbGridView (so that there is room on the right).
saw something like this

$this->widget('bootstrap.widgets.TbGridView',array(
    'id'=>'mining-grid',
    'dataProvider'=>$model->search(),
    'filter'=>$model,
    'type' => 'striped hover', //bordered condensed
        'cssFile'=>'/myapp/css/ie.css',

what should be written in css or can it be done without it?
something like"width"=>array(90%)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Vadim Stepanov, 2015-04-30
@des1roer

www.yiiframework.com/doc/api/1.1/CBaseListView#htm
... most likely you need to register an additional property in this way

...
'htmlOptions' => array('style' => 'width: 90%')
...

D
des1roer, 2015-04-30
@des1roer

<?php $this->widget('bootstrap.widgets.TbGridView',array(
  'id'=>'mining-grid',
  'dataProvider'=>$model->search(),
  'filter'=>$model,
  'type' => 'striped hover', //bordered condensed
        'htmlOptions' => array('style' => 'width: 60%'),

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question