I have a CGridView widget on my Useres/index view. However I would also like to implement a userlook up feature on the same page with a search box at the top that does an ajax autosuggest type of look up of users by username or id. This is different from the type of search that is on admin page. Any ideas how I could implement the same? Yii newbie here. Thanks!
This is kind of what I am trying to accomplish.
<div id="search">
<form action="users/lookup">
<input type="text" id="lookup" name="userid" />
<input type="submit" value="Search" />
</form></div>
<?php $this->widget('zii.widgets.grid.CGridView', array(
'dataProvider'=>$dataProvider,
'pager' => array('cssFile' => Yii::app()->baseUrl. '/css/gridViewStyle/gridView.css'),
'template'=>"{items}
{pager}
{summary}",
There is an example on Yii Playground: Autocomplete. You can add such widgets as a filter in CGridView
.