himiklab/yii2-chained-dropdown-list-widget Chained version of Yii2 DropDownList widget

widgetdropdownchained

Chained DropDownList Widget for Yii2

Chained version of Yii2 DropDownList widget.

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist "himiklab/yii2-chained-dropdown-list-widget" "*"

or add

"himiklab/yii2-chained-dropdown-list-widget" : "*"

to the require section of your application's composer.json file.

Usage

As field in ActiveForm:

use himiklab\chained\ChainedDropDownList;

<?= $form->field($model, 'news')->widget(
    ChainedDropDownList::className(),
    [
        'remote' => [
            'id' => 'language-drop-down',
            'url' => Url::to('newsList')
        ]
    ]
); ?>

As inline field:

use himiklab\chained\ChainedDropDownList;

<?= ChainedDropDownList::widget([
    'remote' => [
        'id' => 'language-drop-down',
        'url' => Url::to('newsList')
    ]
]); ?>

Statistics

Downloads
GitHub Stars
GitHub Forks

Releases

Comments



1.0.0 is the latest of one release



MIT license
Stats
0 github stars & 2 github forks
0 downloads in the last day
102 downloads in the last 30 days
201 total downloads