Taking the example from here:http://www.yiiframew…ntroller#action
If I go
$this->edit();
inside some other method then I get the error:
[font="monospace"]
[/font]
[font=“monospace”]If it’s put as the key in the actions() returned array, shouldn’t it kind of be attached similar to a behavior?[/font]
[font=“monospace”]EDIT: actually, it doesn’t even seem like it’s even bothering to run the actions() method. I put die(); as the first line and it never died.[/font]
[font="monospace"]This is all inside of a module.[/font]
[font=“monospace”]EDIT2: Since I’m not calling the action directly from the url, but from another method in the controller, might I have to manually call createAction first?[/font]
[font="monospace"]EDIT3:[/font]
[font="monospace"]Seems I can go:[/font]
[font="monospace"]
$edit = $this->createAction('edit');
$edit->run();
But I can’t go
$this->edit = $edit
since the property isn’t defined.
Sooo, I think I’m going about this the entirely wrong way.
[/font]
[font=“monospace”]Basically, my goal was to offset some methods that should be grouped together into another controller so this controller didn’t get so long. The method isn’t directly accessed so I suppose it shouldn’t be an action and can just be a normal method. So should I simply use a behavior?[/font]