Download the PHP package mwstake/mediawiki-component-dynamicconfig without Composer

On this page you can find all versions of the php package mwstake/mediawiki-component-dynamicconfig. 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 mediawiki-component-dynamicconfig

Dynamic config

This component is designed to store configuration variables in Database and load (and apply) them from there. It is primarely meant to replace config directory in BlueSpiceFoundation and configs stored in actual static PHP files. It can be used to store any number of configurations, basically everything that goes into LocalSettings.php, except for core configs, like DB connection and similar.

Registering configs

In case your config sets/reads MW globals ($GLOBALS), make it implement MWStake\MediaWiki\Component\DynamicConfig\GlobalsAwareDynamicConfig interface as well.

Using configs

To store config to DB, use

This will call serialize method on the IDynamicConfig object with $dataToBePassedToTheConfig as an argument. This method must return a string to be stored to the Database.

If your config's shouldAutoApply method returns true, the config will be auto-applied on SetupAfterCache hook. Otherwise, you can apply it manually by calling

When applying, method apply will be called on the IDynamicConfig object with the data from the Database as an argument. Config itself is responsible for parsing the data and applying it.

Backups

On every change of a config value, a backup will be made. System will create up to 5 backups, after which it will rotate, deleting the oldest one.

Restoring backups

From code

From CLI

Note: This will assume component is installed in the root vendor directory. If its not, specify path to Maintenance.php, as the first argument of the script.


All versions of mediawiki-component-dynamicconfig with dependencies

PHP Build Version
Package Version
Requires composer/installers Version ~1.0|~2
mwstake/mediawiki-componentloader Version ~1
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 mwstake/mediawiki-component-dynamicconfig contains the following files

Loading the files please wait ....