Download the PHP
package techsterx/slim-config-yaml without Composer
On this page you can find all versions of the php package
techsterx/slim-config-yaml. 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.
Parses YAML files and adds them into Slim's config singleton.
Uses Symfony's YAML Component to parse files (http://github.com/symfony/Yaml).
Allows other YAML files to be imported and parameters to be set and used.
Getting Started
Installation
Composer
Install composer in your project.
Create a file in your project root:
Install via composer:
Add this line to your application's file:
Manual Install
Download and extract src/ directory into your project directory and it in your
application's file.
Methods
Slim Config - YAML uses a static method to get the currenct instance.
If an instance doesn't exist, a new one will be created.
Use the method to get the current instance.
is the shorthand equivalent of .
To add a single file, use the method.
You can also chain multiple methods togethor.
You can import a whole directory of YAML files.
You can chain with the method as well.
Specify some global parameters to be used by all YAML files processed.
Using Parameters
You can specify parameters in YAML files that will be replaced using keywords. Parameters are only available to the resource currently being processed.
config.yaml
app.php
Output:
Importing Files
You can import other YAML files which can be useful to keep all your common parameters in one file and used in others.
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 techsterx/slim-config-yaml contains the following files
Loading the files please wait ....
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.