PHP code example of alwaysblank / rotary

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

    

alwaysblank / rotary example snippets


use AlwaysBlank\Rotary\Render;

echo Render::pretty('1234567890');
// (123) 456-7890

echo Render::pretty('123 456 7890');
// (123) 456-7890

echo Render::pretty('[123)    456/7890');
// (123) 456-7890

use AlwaysBlank\Rotary\Rotary;

$Rotary = new Rotary('123456789');
echo $Rotary->pretty();
// (123) 456-7890