I'm trying to use http://eonasdan.github.io/bootstrap-datetimepicker/ in my Symfony form.
I added:
<link type="text/css" rel="stylesheet" href="{{ asset('assets/css/bootstrap-datetimepicker-standalone.min.css') }}">
<link type="text/css" rel="stylesheet" href="{{ asset('assets/css/bootstrap.min.css') }}">
<script type="text/javascript" charset="utf8" src="{{ asset('assets/js/jquery-3.1.1.min.js') }}"></script>
<script type="text/javascript" charset="utf8" src="{{ asset('assets/js/moment.min.js') }}"></script>
<script type="text/javascript" charset="utf8" src="{{ asset('assets/js/bootstrap.min.js') }}"></script>
<script type="text/javascript" charset="utf8" src="{{ asset('assets/js/bootstrap-datetimepicker.min.js') }}"></script>
But now I'm not sure how do I change my form type to use datepicker
I tried something like this and it's not working
->add('date', DateTimeType::class, array(
'required' => true,
'widget' => 'single_text',
'attr' => [
'class' => 'form-control input-inline datetimepicker',
'data-provide' => 'datetimepicker',
'html5' => false,
],
))
Can someone help me?