PHP code example of hugsbrugs / php-string

1. Go to this page and download the library: Download hugsbrugs/php-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/ */

    

hugsbrugs / php-string example snippets



use Hug\HString\HString as HString;

$string = HString::str_replace_last($search, $replace, $subject);

$bool = HString::starts_with($haystack, $needle);

$bool = HString::ends_with($haystack, $needle);

$bool = HString::is_utf8mb4($search);

phpunit --bootstrap vendor/autoload.php tests