Recommend this page to a friend! |
![]() ![]() |
Info | ![]() |
![]() ![]() |
Reputation | Support forum | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2021-11-07 (9 months ago) ![]() | Not yet rated by the users | Total: 402 | All time: 6,493 This week: 326![]() |
Version | License | PHP version | Categories | |||
php-str-match-split 0.1 | GNU General Publi... | 3.0 | Text processing |
Description | Author | ||||||||||||||||||||||
This class can process strings with regular expressions. |
|
Phpstr Give php strings easy to remember regex functionality ========= Do you ever get tired of looking up preg functions because you forgot the order of the arguments? Me too. ```php require 'phpstr.php'; ``` Return a match ```php str('There are 23 people reading this blog')->match('/\d+/'); ``` Substitution ```php str('all of the es')->gsub('/e/', 'y'); ``` Scan will return an array of matches ```php str('010 202 312 332')->scan('/\d+/'); ``` Split will return an array of tokens ```php str('010 202-312 332')->split('/\s/'); ``` |
![]() |
File | Role | Description |
---|---|---|
![]() |
Class | Class source |
![]() ![]() |
Doc. | Documentation |
![]() ![]() |
Example | Example script |
![]() | php-str-match-split-2021-11-07.zip 1KB |
![]() | php-str-match-split-2021-11-07.tar.gz 1KB |
![]() | Install with Composer |
Version Control | Unique User Downloads | Download Rankings | |||||||||||||||
100% |
|
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.
Related pages |
Give php strings easy to remember regex functionality Blog post describing usage |