2017 © Pedro Peláez
 

library php-dotenv-parser

Allows you get .env file as array and convert array back to .env file

image

jsefton/php-dotenv-parser

Allows you get .env file as array and convert array back to .env file

  • Wednesday, February 28, 2018
  • by jsefton
  • Repository
  • 1 Watchers
  • 3 Stars
  • 135 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 2 Versions
  • 400 % Grown

The README.md

PHP DotEnv Parser

This easy tool allows you to pass a .env file and be returned a parsed array., (*1)

You can then add or edit values from this array., (*2)

This parser also allows you to pass an array and store as a valid .env file to be used., (*3)

Installation

You will need composer to install this package (get composer). Then run:, (*4)

composer require jsefton/php-dotenv-parser

Usage

To parse a .env file to an array pass in the path like below:, (*5)

$env = \Jsefton\DotEnv\Parser::envToArray('/path/to/.env');

To store an array into a .env file pass the array along with the path to store it:, (*6)

\Jsefton\DotEnv\Parser::arrayToEnv($array, '/path/to/.env');

The Versions

28/02 2018

dev-master

9999999-dev https://github.com/jsefton/php-dotenv-parser

Allows you get .env file as array and convert array back to .env file

  Sources   Download

MIT

by Jamie Sefton

parser php env dotenv array-env

08/08 2017

1.0.0

1.0.0.0 https://github.com/jsefton/php-dotenv-parser

Allows you get .env file as array and convert array back to .env file

  Sources   Download

MIT

by Jamie Sefton

parser php env dotenv array-env