Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- echo GridView::widget([
- 'dataProvider' => $provider,
- 'options' => ['style' => 'max-height:30px;',
- 'max-width:10px;',
- ],
- 'columns' => [
- ['class' => 'yiigridSerialColumn',
- 'contentOptions'=>['style'=>'width: 30px;']],
- //subject
- [
- 'attribute' => 'subject',
- 'format' => 'text',
- 'label' => 'Subject',
- 'contentOptions'=>[
- 'style'=>
- ['width: 10px;',],
- ]
- ],
- //body
- [
- 'attribute' => 'body',
- 'format' => 'text',
- 'label' => 'Body',
- 'contentOptions'=>['style'=> 'max-width: 100px;', 'height: 100px']
- ],
- ['class' => 'yiigridActionColumn',
- 'controller'=>null,
- 'header'=>'Action',
- 'headerOptions' => ['width' => '70'],
- ],
- ],
- 'tableOptions' =>['class' => 'table table-striped table-bordered'],
- ]);
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement