* Fix PHP 8.1 deprecation warnings on Helper and FormHelper
- fix deprecation warning when Helper::_entityPath is null
- fix `strftime` function deprecation warning on FormHelper::_getDateTimeValue method
ref: ARCH-11
* Switch deprecated utf8_encode function to mb_convert_encoding function
ref: ARCH-13
* Hide strftime deprecation warning
Since CakePHP 2 doesn't require the installation of `intl` PHP extension in it's documentation, I can't use the alternative `IntlDateFormatter::format` because it relies such extension.
ref: ARCH-13
* Roll back the use of strftime
ref: ARCH-11
* Fix preg_split subject param null deprecated on FormHelper::dateTime
* Fix preg_split deprecated null param limit on CakeResponse::checkNotModified
* fix: get rid of (some) PHP deprecation warnings
- CakeResponse.php strotime() and preg_split() warnings
* Ignore hide srtftime function deprecation warning from PHPCS
* Fix typo on phpcs ignore comments
---------
Co-authored-by: Jan Pešek <jan@sinch.cz>
Warning message: `Deprecated (8192): preg_quote(): Passing null to parameter #1 ($str) of type string is deprecated [vendor/cakephp/cakephp/lib/Cake/Utility/CakeText.php, line 168]`
PHP 8 added support for named parameters however will throw an error when
a named parameter, which does not exist, will be called/appears.
In this case the code uses `array_filter(compact('subject))` to conveniently
prepend `$subject` to the callback, if it's non-null.
It's then combined with `$params` but mixing a hash wih a sequential array
and then end result is `['subject' => …, ]` which then triggers this
TypeError in PHP 8.
The solution applies `array_values()` on above array as to remove the keys
and then the error disappears.
With this change, our internal test suite (2k tests) is green on both PHP8
and PHP7.4, aka this change is expecte to be backwards compatible.
Now Security::encrypt() and Security::decrypt() works with openssl
if the mcrypt extension is unavailable.
Note that Security::rijndael() doesn't work with openssl.
## did
- void unReturn
- miss return void
- add return type
- type miss typing
- add param type and return type
- string → string|array
- change ClassName