enesekinci/php-getenv

Loads environment variables from .env file

v0.2 2021-09-24 13:27 UTC

This package is auto-updated.

Last update: 2021-09-27 08:39:00 UTC


README

Loads environment variables from .env file

<?php

require_once "vendor/autoload.php";

use EnesEkinci\GetEnv\Env as Config;

$file_env = __DIR__ . '/' . '.env';

Config::run($file_env);

$all = Config::get('all');

$app_url = Config::get('APP_URL');