dev-master
9999999-devYii2 lazy params
MIT
The Requires
by Zlakomanov Alexander
extension yii2
v1.0.0
1.0.0.0Yii2 lazy params
MIT
The Requires
by Zlakomanov Alexander
extension yii2
Yii2 lazy params
Yii2 zlay params, (*1)
The preferred way to install this extension is through composer., (*2)
Either run, (*3)
php composer.phar require --prefer-dist zlakomanoff/yii2-lazy-params "*"
or add, (*4)
"zlakomanoff/yii2-lazy-params": "*"
to the require section of your composer.json
file., (*5)
Simple config, (*6)
'lp' => 'zlakomanoff\lazyparams\Component'
Simple usage, (*7)
<?= Yii::$app->lp->get('option', 'default value') ?>
Advanced config, (*8)
'lp' => [ 'class' => 'zlakomanoff\lazyparams\Component', 'tableName' => 'dynamic_options', 'keyColumn' => 'keyword', 'valueColumn' => 'value', 'liquidMode' => false, 'enableCache' => false, 'cacheDefaultValues' => false, 'cacheComponent' => 'cache', 'dbComponent' => 'db' ]
Advanced usage, (*9)
echo Yii::$app->lp['param one']; echo Yii::$app->lp['param two']['default value']; echo Yii::$app->lp->paramThree('default value'); echo Yii::$app->lp->get('param four', 'default value');
Yii2 lazy params
MIT
extension yii2
Yii2 lazy params
MIT
extension yii2