Coming from Slim, CodeIgniter, Yii, CakePHP or Laminas
This page is for developers whose PHP background is one of the classic MVC frameworks or a micro framework. The good news: Exponential's PHP style (classes with static helpers, active record, convention over configuration, arrays as configuration) is closer to CodeIgniter, Yii 1 and CakePHP than to container-heavy frameworks. The difference is that Exponential is content-first: a model of content, permissions and an administration are already there.
Contents
The MVC pieces
| Piece | In your framework | In Exponential 6 |
|---|---|---|
| Controller | a class with action methods | a module view per address (Controllers) |
| Model | active record (CodeIgniter models, Yii ActiveRecord, CakePHP tables and entities) or a table gateway (Laminas) | eZPersistentObject for your tables, the content API for content (ORM) |
| View | PHP templates, Twig or Plates | the template language (The view layer) |
| Routes | a route file or conventions | /<module>/<view> conventions (Routing) |
| Configuration | PHP arrays | INI files in layers (Configuration) |
| Modules, plugins | HMVC modules, Yii modules, CakePHP plugins, Laminas modules | extensions (Packages) |
Framework by framework
| Framework | Familiar | Different |
|---|---|---|
| Slim | small core, you choose the parts; middleware thinking | no PSR-15 pipeline; request rules and listeners instead (Middleware) |
| CodeIgniter | /controller/method/param addresses look like /module/view/param; helpers and libraries | permissions, sessions and CSRF are built in differently (Authentication, Forms and CSRF) |
| Yii | active record, behaviors, modules, a code generator (Gii) | the RAD tools take the place of Gii (RAD tools); RBAC is roles and policies stored as data (Authorization) |
| CakePHP | conventions, bake, plugins, ORM with tables | schema files instead of migrations plugin (Migrations) |
| Laminas, Mezzio | modules, configuration merging, event manager | no service manager (Dependency injection); ezpEvent instead of the event manager (Events) |
PSR standards
Exponential 6 is installed with Composer and loads Composer's autoloader, so PSR-4 libraries work in your extension.
The kernel itself predates PSR-7 and PSR-15: requests are read through eZHTTPTool and eZSys, responses are a result
array or direct output, and there is no PSR-11 container. Do not plan on passing PSR-7 objects through the kernel.
What is new for you
- Content classes replace most tables you would design (The content model).
- Siteaccesses select a whole configuration per request (Siteaccesses).
- Template overrides choose templates by class, node or view mode (Template resolution).
- Workflows hook into publishing and checkout (Workflows).
- Persistent workers under Velocity: no per-request state in statics (Servers and deployment).
Start with Task: build a small CRUD module; it will feel like the first controller you wrote in your framework.
Related pages
- Concept dictionary
- Coming from Symfony, Coming from Laravel
- Autoloads and class naming
- Free documentation: this page is free to copy, translate and improve under the GNU FDL 1.3.
Become an Exponential Partner
Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.