Download the PHP package sebaks/zend-mvc-controller without Composer
On this page you can find all versions of the php package sebaks/zend-mvc-controller. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package zend-mvc-controller
Zend MVC controller implementation
This is controller implementation for Zend MVC builds on sebaks/controller.
Most controllers must do
- Check if that controller\action can be accessed by called method (GET, POST, PUT etc.), if not - rise exception.
- Process request (this is responsibility of sebaks/controller).
- Validate request criteria.
- Validate request data.
- Process request (run any domain service).
- Collect errors.
- Collect result.
- Rise exceptions if error exists.
- Redirect to next page (if define).
- Setup ViewModel.
- Setup MVC Event.
That solution allow to customize any flow parameter and increases code reuse.
Installation
-
Install it via composer by running:
- Copy
./vendor/sebaks/zend-mvc-controller/config/sebaks-zend-mvc-controller.global.php.dist
to./config/autoload/sebaks-zend-mvc-controller.global.php
.
Configuration
You can configure that controller with route params:
criteriaValidator
, changesValidator
- if not defined, will be created Sebaks\Controller\EmptyValidator
service
- if not defined, will be created Sebaks\Controller\EmptyService
request
- if not defined, will be created Sebaks\Controller\Request
response
- if not defined, will be created Sebaks\Controller\Response
viewModel
- if not defined, will be created Zend\View\Model\ViewModel
All versions of zend-mvc-controller with dependencies
zendframework/zend-view Version <2.6 >=2.4
zendframework/zend-http Version <2.6 >=2.4
zendframework/zend-mvc Version <2.6 >=2.4
zendframework/zend-modulemanager Version <2.6 >=2.4
sebaks/controller Version ~0.1.0