Comparing
#3 with
#10
Title
Update content in AJAX with partialRenderrenderPartial
Tags
AJAX
Content
The
most easyeasiest way to update content in AJAX is to use the
partialRenderrenderPartial method.
For this exemple I have three files: a controller (HelloWorldController.php) and two views (index.php and _ajaxContent.php)[...]
<br />
*Note: if using accessRules() in your controller file, you will need to modify accessRules() by adding the appropriate part of the function name to a rule set - in this case* 'updateajax' *like this:*
array('allow', // allow all users to perform 'index' and 'view' actions
'actions'=>array('index','view','updateajax'),
'users'=>array('*'),
),
#### views/helloWorld/index.php
```php[...]
Now, run index.php?r=helloWorld
Enjoy!
### Links
- [Russian Version](http://dbhelp.ru/ajax-partialrender-update/page/)