Difference between #3 and #4 of
CListView AJAX filtering

Revision #4 has been created by Draga on May 5, 2011, 7:49:31 AM with the memo:

formatting
« previous (#3)

Changes

Title unchanged

CListView AJAX filtering

Category unchanged

Tutorials

Yii version unchanged

Tags unchanged

CListView, AJAX, filters

Content changed

This tutorial shows how to filter CListView items by AJAX, and it's compatible with disabled JavaScript users  
In my case this has been done to filter users list
[...]
### Controller

 
CheckBoxes GET parameters are variable (in my case up to 21) so I had to use an array in my controller.  


```php
[...]
. CHtml::button('None', array('id'=>'selectNone'));
```

 
And register the following JavaScript
 
 
~~~
[javascript]
$('#selectAll').click(function(){
$('.categoryFilter').attr('checked','checked')
category = $('.categoryFilter').serialize();
$.fn.yiiListView.update(
[...]
13 0
27 followers
Viewed: 66 355 times
Version: 1.1
Category: Tutorials
Written by: Draga
Last updated by: Draga
Created on: May 5, 2011
Last updated: 7 years ago
Update Article

Revisions

View all history