Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 16 additions & 11 deletions en/appendices/5-0-migration-guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,18 @@ Global
aliases be sure to add ``require CAKE . 'functions.php'`` to you application's
``config/bootstrap.php``.

Cache
-----

- The ``Wincache`` engine was removed. The wincache extension is not supported
on PHP 8.

Auth
----

- `Auth` has been removed. Use the `cakephp/authentication <https://book.cakephp.org/authentication/2/en/index.html>`__ and
`cakephp/authorization <https://book.cakephp.org/authorization/2/en/index.html>`__ plugins instead.

Cache
-----

- The ``Wincache`` engine was removed. The wincache extension is not supported
on PHP 8.

Console
-------

Expand Down Expand Up @@ -81,17 +81,18 @@ Core
Database
--------

- The ``DateTimeType`` and ``DateType`` now always return immutable objects.
Additionally the interface for ``Date`` objects reflects the ``ChronosDate``
interface which lacks all of the time related methods that were present in
CakePHP 4.x.
- ``DateType::setLocaleFormat()`` no longer accepts an array.
- ``Query`` now accepts only ``\Closure`` parameters instead of ``callable``. Callables can be converted
to closures using the new first-class array syntax in PHP 8.1.
- ``Query::execute()`` no longer runs results decorator callbacks. You must use ``Query::all()`` instead.
- ``TableSchemaAwareInterface`` was removed.
- ``Driver::quote()`` was removed. Use prepared statements instead.
- ``Query::orderBy()`` was added to replace ``Query::order()``.
- ``Query::groupBy()`` was added to replace ``Query::group()``.
- The ``DateTimeType`` and ``DateType`` now always return immutable objects.
Additionally the interface for ``Date`` objects reflects the ``ChronosDate``
interface which lacks all of the time related methods that were present in
CakePHP 4.x.
- ``SqlDialectTrait`` has been removed and all its functionality has been moved
into the ``Driver`` class itself.
- ``CaseExpression`` has been removed and should be replaced with
Expand Down Expand Up @@ -131,7 +132,11 @@ Http
I18n
----

- `Time` was renamed to `DateTime` to allow for future time-only types.
- ``Time`` was renamed to `DateTime` to allow for future time-only types.
- ``Date::parseDateTime()`` was removed.
- ``Date::parseTime()`` was removed.
- ``Date::setToStringFormat()`` and ``Date::setJsonEncodeFormat()`` no longer accept an array.
- ``Date::i18nFormat()`` and ``Date::nice()`` no longer accept a timezone parameter.
- Translation files for plugins with vendor prefixed names (``FooBar/Awesome``) will now have that
prefix in the file name, e.g. ``foo_bar_awesome.po`` to avoid collision with a ``awesome.po`` file
from a corresponding plugin (``Awesome``).
Expand Down