public static function getEnv()
    {   
        if (null !== (getenv('P_DRIVER'))) {

            $dotEnv = new Dotenv($_SERVER['DOCUMENT_ROOT']);
            $dotEnv->load();
        }    
      
        self::$driver  = getenv('P_DRIVER');
        self::$host    = getenv('P_HOST');
        self::$dbname  = getenv('P_DBNAME');
        self::$user    = getenv('P_USER');
        self::$pass    = getenv('P_PASS');  
    }
public static function getEnv()
    {   
        if (null !== (getenv('P_DRIVER'))) {

            $dotEnv = new Dotenv($_SERVER['DOCUMENT_ROOT']);
            $dotEnv->load();
        }    
      
        self::$driver  = getenv('P_DRIVER');
        self::$host    = getenv('P_HOST');
        self::$dbname  = getenv('P_DBNAME');
        self::$user    = getenv('P_USER');
        self::$pass    = getenv('P_PASS');  
    }
public static function getEnv ( ) { if ( null !== ( getenv ( 'P_DRIVER' ) ) ) { $ dotEnv = new Dotenv ( $ _SERVER [ 'DOCUMENT_ROOT' ] ) ; $ dotEnv -> load ( ) ; } self :: $ driver = getenv ( 'P_DRIVER' ) ; self :: $ host = getenv ( 'P_HOST' ) ; self :: $ dbname = getenv ( 'P_DBNAME' ) ; self :: $ user = getenv ( 'P_USER' ) ; self :: $ pass = getenv ( 'P_PASS' ) ; }
Get environment values from .env file

@return null
Get environment values from . env file