#phpdotenv — Public Fediverse posts
Live and recent posts from across the Fediverse tagged #phpdotenv, aggregated by home.social.
-
Hint: When using something like vlucas/phpdotenv, which populates a superglobal, there's no need of attribution, you can just isolate the return of createX and chain methods.
Intead of:
$env = Dotenv::createImmutable($yourPath);
$env->load(); // $_ENV becomes populatedYou can do:
(Dotenv::createImmutable($yourPath))->load(); // $_ENV becomes populated**#php** **#phpdotenv** **#env** **#dotenv**