Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/386.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 无法使引导日期时间选择器正确显示_Javascript_Jquery_Twitter Bootstrap - Fatal编程技术网

Javascript 无法使引导日期时间选择器正确显示

Javascript 无法使引导日期时间选择器正确显示,javascript,jquery,twitter-bootstrap,Javascript,Jquery,Twitter Bootstrap,我试图使用引导DateTimePicker,但它在屏幕上显示不正确。我的HTML如下所示 <div class='input-group date' id='startDate'> <input type='text' class="form-control" name="startDate" /> <span class="input-group-addon"><span class="glyphicon glyphic

我试图使用引导DateTimePicker,但它在屏幕上显示不正确。我的HTML如下所示

<div class='input-group date' id='startDate'>
        <input type='text' class="form-control" name="startDate" />
        <span class="input-group-addon"><span class="glyphicon glyphicon-calendar"></span>
</div>
$(document).ready(function () {
            // DateTime picker for Dates
            $("#startDate").datetimepicker();
});
我加载javascript和css文件的顺序如下

<link href="/Content/css/datepicker.css" rel="stylesheet"/>
<link href="/Content/css/bootstrap-datetimepicker.css" rel="stylesheet"/>
<link href="/Content/css/bootstrap.css" rel="stylesheet"/>

<script src="/Scripts/jquery-2.1.0.js"></script>
<script src="/Scripts/jquery-ui-1.10.0.custom.js"></script>
<script src="/Scripts/bootstrap-datepicker.js"></script>
<script src="/Scripts/bootstrap.js"></script>
<script src="/Scripts/moment.js"></script>
<script src="/Scripts/bootstrap-datetimepicker.js"></script>
通过以上设置,datetime选择器显示如下,没有任何正确的css。更改月份的箭头按钮显示不正确


我尝试更改顺序,但仍然显示相同的顺序。有人能帮我解决我缺少的东西吗?

好的,检查一下这把小提琴:

您不需要jquery ui或引导datepicker,只需要引导datetimepicker和moment.js

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

$(document).ready(function () {
    // DateTime picker for Dates
    $("#startDate").datetimepicker();
});

好的,检查这把小提琴:

您不需要jquery ui或引导datepicker,只需要引导datetimepicker和moment.js

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

$(document).ready(function () {
    // DateTime picker for Dates
    $("#startDate").datetimepicker();
});
为什么同时使用和?你不能只使用datepicker脚本吗?为什么同时使用和?你就不能用datepicker脚本吗?