Home
extends BaseController
in package
Class BaseController
BaseController provides a convenient place for loading components and performing functions that are needed by all your controllers. Extend this class in any new controllers: class Home extends BaseController
For security be sure to declare any new methods as protected or private.
Table of Contents
Properties
- $data : mixed
- $helpers : array<int, string>
- An array of helpers to be loaded automatically upon class instantiation. These helpers will be available to all other controllers that extend BaseController.
- $request : CLIRequest|IncomingRequest
- Instance of the main Request object.
- $user : mixed
Methods
- dashboard() : string
- get_live_route() : mixed
- initController() : void
Properties
$data
protected
mixed
$data
= []
$helpers
An array of helpers to be loaded automatically upon class instantiation. These helpers will be available to all other controllers that extend BaseController.
protected
array<int, string>
$helpers
= ['device', 'download', 'csrf', 'user', 'front/dashboard', 'admin/header', 'admin/footer']
$request
Instance of the main Request object.
protected
CLIRequest|IncomingRequest
$request
$user
protected
mixed
$user
Methods
dashboard()
public
dashboard() : string
Return values
stringget_live_route()
public
get_live_route(string $route, mixed ...$args) : mixed
Parameters
- $route : string
- $args : mixed
initController()
public
initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger) : void
Parameters
- $request : RequestInterface
- $response : ResponseInterface
- $logger : LoggerInterface