ezekel
(Dixunei)
1
I tried to format the date when I select date on datepicker
<?= $form->field($modelheader,'mydate')->widget(DatePicker::className(),
['clientOptions' => ['dateFormat' => 'yy-mm-dd',]
])
?>
but it did not format it always show like this
I don’t know what’s wrong on this,but I followed what the guides says on how to format.
Thank you in advance.
evercode
(Ikon321)
2
It’s a known issue, see this post.
ezekel
(Dixunei)
3
Thank you for the quick reply.
CEBE said.
where I will put this code
['myDate', 'date', 'timestampAttribute' => 'myDate']
ezekel
(Dixunei)
4
I think it works now.
I tried @qiang suggested.
Thank you.