Closed BoguckiM closed 5 years ago
Hi.
Yii 2.0.16.1 kartik-v/yii2-widget-select2 2.1.3
Init: <?= $form->field($model, 'pagea[]')->widget(Select2::classname(), [ 'pluginOptions' => [ 'ajax' => [ 'url' => Url::to('searchpage'), 'dataType' => 'json', ], 'createTag' => 'createTag', 'minimumInputLength' => 3, 'tags' => true, ], ], ) ?>
<?= $form->field($model, 'pagea[]')->widget(Select2::classname(), [ 'pluginOptions' => [ 'ajax' => [ 'url' => Url::to('searchpage'), 'dataType' => 'json', ], 'createTag' => 'createTag', 'minimumInputLength' => 3, 'tags' => true, ], ], ) ?>
Why does tags not it work?
The 'createTag' function must be given by 'new JsExpression (' ... ')'
That's correct.
Hi.
Yii 2.0.16.1 kartik-v/yii2-widget-select2 2.1.3
Init:
<?= $form->field($model, 'pagea[]')->widget(Select2::classname(), [ 'pluginOptions' => [ 'ajax' => [ 'url' => Url::to('searchpage'), 'dataType' => 'json', ], 'createTag' => 'createTag', 'minimumInputLength' => 3, 'tags' => true, ], ], ) ?>
Why does tags not it work?