redacteddevworks / preg_match2
PHP Regex Matcher that returns the matched values
Installs: 1 161
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
Open Issues: 0
This package is auto-updated.
Last update: 2025-06-22 06:05:28 UTC
README
Why?
I simply would prefer if the built in preg_match functions would just return the values instead of the current method of supplying a predefined array.
Installation
composer require redacteddevworks/preg_match2
Usage
require 'autoload.php';
$matches = preg_match2('/([\d])/', 'the quick 1 jumped over the lazy 2 dog');