I have a Problem with a Autocomplete Field in an Ajax Area. This is my Autocomplete Widget wich is working if i load the complete Page. But the Widget is in an Area, which will be reloaded by Ajax (i didn’t use Pjax). After this reload, the Widget is not working anymore.
How can i solve this?
Thank!
<?= $form->field($suche, 'text')
->label(false)
->widget(\yii\jui\AutoComplete::classname(), [
'options' => ["placeholder"=>"Suchen..."],
'clientOptions' => [
'autoFill' => true,
'minLength' => '2',
'source' => "/site/typesearch",
'select' => new JsExpression("
function( event, ui ) {
$(this).submit();
}"),
],
]) ?>