<?php Pjax::begin(); $gridColumns = [ [ 'attribute' => 'avance', 'headerOptions' => ['style' => 'text-align:center; '], 'contentOptions' => ['style' => 'text-align:center; vertical-align:middle;'], 'format' => 'raw', 'value' => function($model) { $string = $model->observacion; $wrappedString = wordwrap($string, 40, "\n"); return '<div style="max-height: 80px; overflow: auto; max-width: 200px;">' . nl2br($wrappedString) . '</div>'; }, ], [ 'attribute' => 'observacion', 'headerOptions' => ['style' => 'text-align:center; '], 'contentOptions' => ['style' => 'text-align:center; vertical-align:middle;'], 'format' => 'raw', 'value' => function($model) { $string = $model->observacion; $wrappedString = wordwrap($string, 40, "\n"); return '<div style="max-height: 80px; overflow: auto; max-width: 200px;">' . nl2br($wrappedString) . '</div>'; }, ], ]; ?>