PHP code example of openlss / func-format

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

    

openlss / func-format example snippets


//Format bytes into an arbitrary divisor
echo format_bytes(1048576); //1MB

//Create list friendly IP's
echo format_ip('1.2.3.4'); //  1.  2.  3.  4