PHP code example of legolabs / phputils

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

    

legolabs / phputils example snippets


use Legolabs\Utils\EnvReplacer\EnvReplacer;

$replacer = new EnvReplacer('/etc/php/8.1/apache/php.ini');
$replacer->apply();
ini
...
upload_max_filesize = __UPLOAD_MAX_FILESIZE__
max_file_uploads = __MAX_FILE_UPLOADS__
...
bash
export UPLOAD_MAX_FILESIZE=64M
export MAX_FILE_UPLOADS=20
ini
...
upload_max_filesize = 64M
max_file_uploads = 20
...