PHP 8.5.0 Released!

Voting

The Note You're Voting On

nicoSWD
5 years ago
PHP 8 has a native function to retrieve the actual error message, so these helper functions are no longer necessary. https://www.php.net/preg_last_error_msg <?php preg_match('/(?:\D+|<\d+>)*[!?]/', 'foobar foobar foobar'); if (preg_last_error() !== PREG_NO_ERROR) { echo preg_last_error_msg(); // Prints "Backtrack limit exhausted" } ?>

<< Back to user notes page

To Top