Download the PHP package sinergi/config without Composer

On this page you can find all versions of the php package sinergi/config. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package config

Config

Build Status StyleCI Scrutinizer Code Quality Code Coverage Code Climate Latest Stable Version Total Downloads License SensioLabsInsight Gitter

PHP configurations loading library. It is made to enable your application to have different configurations depending on the environment it is running in. For example, your application can have different configurations for unit tests, development, staging and production.

A good practice would be to not include your production or staging configurations in your version control. To do this, Config supports Dotenv.

Requirements

This library uses PHP 5.6+.

Installation

It is recommended that you install the Config library through composer. To do so, run the Composer command to install the latest stable version of Config:

Usage

Use the factory to instanciate a Config collection class:

Optionally, you can also setup the environment. Setting up the environment will merge normal configurations with configurations in the environment directory. For example, if you setup the environment to be prod, the configurations from the directory configs/prod/* will be loaded on top of the configurations from the directory configs/*. Consider the following example:

Optionally, you can also use dotenv to hide sensible information into a .env file. To do so, specify a directory where the .env file. Like in this example:

You can than use the configurations like this:

Getter

The configuration getter uses a simple syntax: file_name.array_key.

For example:

You can optionally set a default value like this:

You can use the getter to access multidimensional arrays in your configurations:

Setter

Alternatively, you can set configurations from your application code:

You can set entire arrays of configurations:

Examples

See more examples in the examples folder.

PHP Configuration File

Example of a PHP configuration file:

Yaml Configuration File

Example of a YAML configuration file:

Dotenv

Example of using Dotenv in a PHP configuration file:

And in the .env file:

License

Config is licensed under The MIT License (MIT).


All versions of config with dependencies

PHP Build Version
Package Version
Requires php Version >=5.6
sandrokeil/interop-config Version >=0
container-interop/container-interop Version >=1
vlucas/phpdotenv Version >=2
symfony/yaml Version >=2
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package sinergi/config contains the following files

Loading the files please wait ....