Answer the question
In order to leave comments, you need to log in
YII2. How to load datepicker widget with ajax?
It is necessary to load the code block containing the DatePicker calendar into the form with Ajax.
But when loading the plugin does not work, tell me how to solve the problem
Ajax works properly, DatePicker does not work
<?= $form->field($prices,'date_to')
->widget(
DatePicker: :className(),[
'dateFormat' => 'yyyy-MM-dd',
])
?>
And if the DatePicker loads with the page, then no problem
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question