SEARCH
0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Prev | Current Page 107 | Next

James Kennard

"Mastering Joomla! 1.5 Extension and Framework Development"


When the execute() method is performed the controller will also perform an
authorization check. For more information about how to define permissions, refer to
Chapter 11.
Unlike models and views there are is no specific naming convention to which we
must adhere when we define a controller class. The core controllers tend to use the
format: component name, the word 'Controller', and optionally the entity name.
For example, we might choose to name our controller
MyextensionControllerFoobar. We will assume we only have the one entity, so we
will name our example controller MyextensionController.
Controllers are normally located in a folder called controllers, or, if there is only
one controller, it is in the root of the component in a file called controller.php.
Wherever you choose to locate your controllers, you will have to
import them manually.
To use the abstract JController class we must import the joomla.application.
component.controller library; this guarantees that the JController class is available
to be extended.


Pages:
95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119