PHP code example of cjrasmussen / string

1. Go to this page and download the library: Download cjrasmussen/string library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

cjrasmussen / string example snippets


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