home.social

#phpdotenv — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #phpdotenv, aggregated by home.social.

  1. 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 populated

    You can do:
    (Dotenv::createImmutable($yourPath))->load(); // $_ENV becomes populated

    **#php** **#phpdotenv** **#env** **#dotenv**