datetime - Rails: datetime_field does not display control buttons -
i have form, use date_field
helper , works well, control buttons shown, when change datetime_field
field displayed control buttons no displayed.
my date_field
works fine:
=f.date_field :publishing_date, placeholder: "yyyy-mm-dd", class: "form-control"
the datetime_field
not shown controls:
=f.datetime_field :publishing_date, class: "form-control"
finally, realized there 2 form helpers select datetime: datetime_field
(which using) , datetime_local_field
(html5).
the first 1 datetime_field
rendered input
type datetime
. second 1 datetime_local_field
rendered input
datetime-local
type looking for, works fine , introduced in html5, if want use browser not support html5, displayed input
type datatime
.
Comments
Post a Comment