cjrasmussen / string
Simple functions for string manipulation and analysis
1.2.6
2024-06-14 04:47 UTC
Requires
- php: >=7.4.0
- ext-json: *
README
Simple functions for string manipulation and analysis.
Usage
use cjrasmussen\String\Strings; $string = Strings::filterChars('I have 5 apples', Strings::FILTER_NUM); echo $string; // 5 $json = Strings::isJson('This is not JSON'); echo $json; // false
Installation
Simply add a dependency on cjrasmussen/string to your composer.json file if you use Composer to manage the dependencies of your project:
composer require cjrasmussen/string
Although it's recommended to use Composer, you can actually include the file(s) any way you want.
License
String is MIT licensed.