bootstrap datetimepicker installation

主宰稳场 提交于 2019-12-02 09:40:22

Check manual installation guide here.

You must include:

  • jQuery
  • Moment.js
  • Bootstrap + collapse + transitions

So the files needed would be:

  • bootstrap.min.js
  • bootstrap.min.css
  • moment-with-locales.js
  • bootstrap-datetimepicker.css
  • bootstrap-datetimepicker.js

Check this fiddle for a working example.

HTML:

<br/>
<!-- padding for jsfiddle -->
<div class="row">
    <div class="col-md-12">
         <h6>datetimepicker1</h6>

        <div class="form-group">
            <div class="input-group date" id="datetimepicker1">
                <input type="text" class="form-control" />  <span class="input-group-addon"><span class="glyphicon-calendar glyphicon"></span></span>
            </div>
        </div>
    </div>
</div>

JS:

$('#datetimepicker1').datetimepicker();
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!