1. Go to this page and download the library: Download hedii/helpers 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/ */
hedii / helpers example snippets
$string = string_without('This is my name', ' is ');
// Thismy name
$string = string_without('This is my name', 'some string');
// This is my name
$string = string_before('This is my name', ' name');
// This is my
$string = string_before('This is my name', 'some string');
// false
$string = string_after('This is my name', 'This ');
// is my name
$string = string_after('This is my name', 'some string');
// false
$string = string_between('This is my name', 'This ', ' name');
// is my
$string = string_between('This is my name', 'some', ' string');
// false
$value = string_starts_with('This is my name', 'This');
// true
$value = string_ends_with('This is my name', 'name');
// true