[Solved] Gridview Filtering Problem

I have a table that is holding information on contacts. There is a boolean to indicate the type of contact. I am using a CGridView to display the information on the controller index page.


  1. Of the columns only one (company_name) needs to searched. I would like to hide/not show, all of the filter boxes at the top of the grid. Set ‘filter’=>null is not an option, see below.

  2. I have tried to reproduce the advance search code from the default admin.php page. I am getting the Java busy icon, but no results. Both with ‘filter’=>$model and 'filter=>null.

  3. I would like to use a namedScope in display/search criteria.

Found it 8)

For those who may need it. The nothing happening was because I forgot to set $model->attributes if something was coming back. For the namedScope (‘support’) problem see the $this->render() in the below code:

        if (isset($_GET['SupportLink'])) {

            $model->attributes = $_GET['SupportLink'];


        $this->pageTitle = Yii::app()->name . ' - Support Contacts';

        $this->breadcrumbs = array(

            'Engineering' => array('/engineering/index'),

            'Support Contacts',


        $this->render('links', array(

            'model' => $model->support(),