PHP Classes

PHP Easy Configuration: Load and set configuration values from PHP scripts

Recommend this page to a friend!
  Info   View files Example   View files View files (5)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 225 All time: 8,179 This week: 226Up
Version License PHP version Categories
easy-configuration 1GNU General Publi...5PHP 5, Configuration
Collaborate with this project 

Author

easy-config-class - github.com

Description

This class can load and set configuration values from PHP scripts.

It can load a PHP script from the config directory that defines configuration values setting in arrays.

The class and also set and get specific configuration values.

Picture of Ashok kumar  kashyap
  Performance   Level  
Name: Ashok kumar kashyap <contact>
Classes: 4 packages by
Country: India India
Age: 37
All time rank: 2051127 in India India
Week rank: 587 Up47 in India India Up

Example

<?php

/*
* @author Ashok kashyap
* @authoremail ajayashok.01@gmail.com,ashok@yesweexpert.com
* @authorwebsite http://yesweexpert.com
* @facebook https://www.facebook.com/er.ashokkashyap, https://www.facebook.com/yesweexpert
* @version 1.0
*/

include "config.php";
$con= new EasyConfig(); // create the config class object
$con->load("app_seting");

//$con->load("email_config"); // load any file from config directory, just pass the file as parameter when you calling the load function of the config class

echo "<br>".DIR_PATH;
echo
$con->set('APPLICATION_PATH',DIR_PATH); // set any new danamic key=> value pair for config setting for your application

echo $con->set('copyright_text','all &copy; are reserved for EES'); // set any new danamic key=> value pair for config setting for your application

easy_debug_data($con->data); // display all key pair for the your application

echo $con->get('appname'); // get the single key value from your configuration file


  Files folder image Files  
File Role Description
Files folder imageconfig (1 file)
Plain text file config.php Class Class source
Plain text file example.php Example Example script
Plain text file read-me.txt Doc. Documentation
Plain text file README.md Doc. Documentation

  Files folder image Files  /  config  
File Role Description
  Plain text file app_setting.php Aux. Auxiliary script

 Version Control Unique User Downloads Download Rankings  
 100%
Total:225
This week:0
All time:8,179
This week:226Up