javascript - How to avoid seconds in datetimepicker? -
i want avoid seconds in datepicker dropdown.
have following html content:
<link href="<c:url value='/resources/css/bootstrap-datetimepicker.min.css'/>" rel="stylesheet"> <script type="text/javascript" src="<c:url value='/resources/js/bootstrap-datetimepicker.min.js'/>"></script> ... <div id="starttimediv" class="input-append right-date-input"> <input id="starttime" name="starttime" data-format="hh:mm:ss" type="text" value=""> <span class="add-on"> <i data-time-icon="icon-time" data-date-icon="icon-calendar"> </i> </span> </div>
and following js:
$('#starttimediv').datetimepicker({ pickdate: false, timeformat: "hh:mm" });
starttimediv looks this:
thus seconds didn't disappear. why ?
p.s.
tried reproduce scratch on isolated example , works correctly. suppose can problem libraries interaction or different version used on isolated example. don't how check datepicker version use.
where getting #starttimediv from? should not #starttime, may solve issues :)
Comments
Post a Comment