PHP code example of pikl-cz / config-params

1. Go to this page and download the library: Download pikl-cz/config-params library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

pikl-cz / config-params example snippets


use Pikl\ConfigParams;

class BasePresenter extends Nette\Application\UI\Presenter {

	/** @var Pikl\ConfigParams */
	public $configParams;
	
	public function injectConfigParams(ConfigParams $configParams) {
        	$this->configParams = $configParams;
    	}

	function startup() {
		parent::startup();
		$this->template->debugMode = $this->configParams->getDebugMode();
	}

}