After much anticipation, PHP 8.4 has finally released its first official version. PHP 8.4 maintains a high degree of backward compatibility from PHP 8.0 to 8.4 and introduces several new features.
New/Changed Features in PHP 8.4
-
curl_getinfo
now supportsCURLINFO_POSTTRANSFER_TIME_T
-
curl_version()
supportsfeature_list
- New functions:
http_(get|clear)_last_response_headers
- New option:
CURLOPT_PREREQFUNCTION
- New option:
CURLOPT_DEBUGFUNCTION
- New option:
CURLOPT_SERVER_RESPONSE_TIMEOUT
, replacingCURLOPT_FTP_RESPONSE_TIMEOUT
- New option:
CURLOPT_TCP_KEEPCNT
- New
round()
function - New functions:
mb_trim
,mb_ltrim
, andmb_rtrim
-
DateTime(Immutable)
class now hascreateFromTimestamp
method -
phpinfo
now displays PHP integer size information -
DateTime(Immutable)
class addsget/setMicrosecond
methods - New function:
request_parse_body
- Upgraded PCRE2 with related regex changes
Syntax/Function Changes in PHP 8.4
- OpenSSL: Minimum required OpenSSL version increased to 1.1.1
- MBString: Unicode character database updated to version 16
-
exit
/die
changed from language constructs to functions -
CURLOPT_DNS_USE_GLOBAL_CACHE
is now deprecated - Password Hashing: Default Bcrypt cost increased from 10 to 12
-
PHP_ZTS
andPHP_DEBUG
constant value types changed fromint
tobool
- Opcache: INI changes for enabling JIT
-
round()
function: Invalid rounding modes will throw aValueError
exception - Curl: Minimum required libcurl version increased to 7.61.0
Deprecated Features in PHP 8.4
- Implicit nullable parameter declarations are deprecated
-
E_STRICT
constant is deprecated - Using more than 2 parameters with
session_set_save_handler()
is deprecated - CSV: The
$escape
parameter must be provided -
CURLOPT_BINARYTRANSFER
is deprecated
Removed Features in PHP 8.4
- Pspell extension moved from PHP core to PECL
- IMAP extension moved from PHP core to PECL
- OCI8 and PDO-OCI extensions moved from PHP core to PECL
Use ServBay to deploy your development environment and quickly experience the latest version of PHP!
Big thanks for sticking with ServBay. Your support means the world to us 💙.
Got questions or need a hand? Our tech support team is just a shout away. Here’s to making web development fun and fabulous! 🥳
If you want to get the latest information, follow X(Twitter) and Facebook.
If you have any questions, our staff would be pleased to help, just join our Discord community, Telegram or Whats app.