0
votes

I would like to keep focus on the last filter input field in the gridview, so when I type something in column 1, and then press tab, the focus jumps to the filter input field of the next column, then the page is being refreshed, and I would like it to keep the focus on the second input filter field.

I've found an article about the same issue for Yii1.1, and I've tried to implement it, but unfortunately, I'm not yet so professional to achieve that. Can you please help me how can I implement the above solution or create a new one to make it work? It's quite annoying that you always have to set the focus for filtering further.

My Pjax in GridView looks like this (generated by giiant):

<?php \yii\widgets\Pjax::begin(['id' => 'pjax-main', 'enableReplaceState' => false, 'linkSelector' => '#pjax-main ul.pagination a, th a', 'clientOptions' => ['pjax:success' => 'function(){alert("yo")}']]) ?>

Otherwise it's a simple GridView widget.

1
Is it not working only for me, or does it disturb only me...? Please... - user2511599

1 Answers

0
votes

There may be problem of "Pjax timeout", Please increase timeout property of PJAX

Pjax::begin(['timeout'=>10000]);