You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
dongbeta edited this page Jul 28, 2011
·
1 revision
Controller
The Controller classes in Xoops are instances of Xoops_Zend_Controller_Action. By default, the first segment of a URL path maps to a controller, and the second to an action. For example, given the URL http://framework.zend.com/roadmap/components , the path is /roadmap/components, which will map to the controller roadmap and the action components. If no action is provided, the action index is assumed, and if no controller is provided, the controller index is assumed (following the Apache convention that maps a DirectoryIndex automatically).
When a controller runs, it performs the requested action. Action is the basic unit in the Controller. The action function name is lower-cased, and the word Action is appended. Thus, in our example above, the action components becomes componentsAction(), and the final method called is RoadmapController::componentsAction().
Then, you can do anything you need in the actions.