$(...)。datetimepicker不是函数为什么我会收到此错误?

时间:2016-07-15 15:52:54

标签: twitter-bootstrap bootstrap-datetimepicker

我正在尝试实现Bootstrap DateTimePicker,但我收到了错误

  

未捕获的TypeError:$(...)。datetimepicker不是函数

这是我的javascript文件

<script src="/Scripts/jquery-1.9.1.min.js"></script>
<script src="/Scripts/moment.js"></script>
<script src="/Scripts/bootstrap.min.js"></script>
<script src="/Scripts/bootstrap-datetimepicker.js"></script>
<script src="/Scripts/Cleaner.js"></script>

这是我的css文件

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

这是html

<div>
    <div>
        <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>

        <h6>datetimepicker2</h6>
        <input type="text" class="form-control" id="datetimepicker2" />
    </div>
</div>

这是jQuery

$('#datetimepicker1').datetimepicker();  
$('#datetimepicker2').datetimepicker();

(我知道之前有人问过,但解决方案似乎都不适用于我)

任何帮助将不胜感激。谢谢!

0 个答案:

没有答案