Difference between #6 and #7 of
How to use a Widget as an Action Provider

Revision #7 has been created by Antonio Ramirez on Jan 19, 2012, 2:14:23 PM with the memo:

Fixed minor typing error
« previous (#6) next (#9) »

Changes

Title unchanged

How to use a Widget as an Action Provider

Category unchanged

How-tos

Yii version unchanged

Tags unchanged

Widgets, CAction

Content changed

[...]
All done, now we can call all the **actionProvider** actions as **controllerID/actionPrefix.actionID**. Here is the example:


```php
index.php?
r=site/test.GetData
```

###Passing Parameters to Actions
As you all know, and already explained in the wiki [Actions Code Reuse with CAction](http://www.yiiframework.com/wiki/170/actions-code-reuse-with-caction/ "Actions Code Reuse with CAction"), Actions are classes that extend from CAction, that is, a CComponent. If we wish to pass parameters to the actions that are within the provider, we have to do it this way when configuring your controller (step 3) (Thanks to [Attilio](http://www.yiiframework.com/user/25057/ "Attilio") for pointing this out):
[...]
24 0
41 followers
Viewed: 59 906 times
Version: 1.1
Category: How-tos
Written by: Antonio Ramirez
Last updated by: stinkytofu
Created on: Feb 18, 2011
Last updated: 8 years ago
Update Article

Revisions

View all history