Did a small scan on the current Phalcon40 project. And noticed the following.
Not sure how to define this in the yaml and if it's even possible.
1. Flash ✔️
https://docs.phalcon.io/4.0/en/upgrade#flash
Constructor param should be set using setCssClasses
-$flash = new Phalcon\Flash([mixed $cssClasses])
+$flash = new Phalcon\Flash()
+$flash->setCssClasses($cssClasses)
2. Param order ✔️
https://docs.phalcon.io/4.0/en/upgrade#mvcmodel
Param order changed.
-Phalcon\Model::assign(array $data, mixed $dataColumnMap = null, array $whiteList = null)
+Phalcon\Model::assign(array $data, mixed $whiteList = null, mixed $dataColumnMap = nul)
What url should be handed is now the responsibility of the user.
3. Application Factory ✔️
Before
<?php
$application = new Phalcon\Mvc\Application($di);
try {
$response = $application->handle();
$response->send();
} catch (\Exception $e) {
echo 'Exception: ', $e->getMessage();
}
Phalcon 4
<?phpx
$container = new Phalcon\Di\FactoryDefault();
$application = new Phalcon\Mvc\Application($container);
try {
$response = $application->handle(
$_SERVER["REQUEST_URI"]
);
$response->send();
} catch (\Exception $e) {
echo $e->getMessage();
}
Did a small scan on the current Phalcon40 project. And noticed the following.
Not sure how to define this in the yaml and if it's even possible.
1. Flash ✔️
https://docs.phalcon.io/4.0/en/upgrade#flash
Constructor param should be set using setCssClasses
2. Param order ✔️
https://docs.phalcon.io/4.0/en/upgrade#mvcmodel
Param order changed.
What url should be handed is now the responsibility of the user.
3. Application Factory ✔️
Before
Phalcon 4