My question refers to the following bootstrap 3 date time picker:
https://eonasdan.github.io/bootstrap-datetimepicker/
I have a bootstrap 3 date and time picker
It's a bug of the datetimepicker, if you look at the code you will see that it internally uses the isEnabled function to determine which component to show. The isEnabled
determines if the date picker should be shown checking if the format contains a D
(case insensitive). Unfortunately, it does not takes in account string escaping []
.
If the format
option does not contain Y
, M
, d
and D
, the component will work as expected, as shown in the following example:
$('#datetimepicker').datetimepicker({
defaultDate:'now',
ignoreReadonly: true,
format: '[abc:] LT'
});
I found that is a already known issue and there is a open pull request that tries to fix it. If you need, you can try to change the libary code locally with the code proposed by the pull request.