PHP code example of brianium / habitat
1. Go to this page and download the library: Download brianium/habitat 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/ */
brianium / habitat example snippets
use Habitat\Habit;
//equivalent of getenv('FOO')
$foo = Habitat::getenv('FOO');
//equivalent of putenv('FOO=BAR')
$wasSet = Habitat::putenv('FOO=BAR');
/**
* Returns $_ENV if set, otherwise set $_ENV via phpinfo() and
* return it
*/
$all = Habitat::getAll();