使用datepicker插件我收到以下错误
TypeError:$(...)。daterangepicker不是函数 HTMLDocument.eval(eval at (https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js:2:2538), :6:31)at m.Callbacks.j(eval at (https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js:2:2538), :2:27295)at Object.m.Callbacks.k.add [as done](eval 在
答案 0 :(得分:0)
XTemplate evaluation exception: wrapperStyle is not defined

$(function() {
$('input[name="daterange"]').daterangepicker();
});

请确保您按正确的顺序包含了正确的脚本文件:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="//cdn.jsdelivr.net/momentjs/2.9.0/moment.min.js"></script>
<link rel="stylesheet" type="text/css" href="//cdn.jsdelivr.net/bootstrap/3.3.2/css/bootstrap.css" />
<!-- Include Date Range Picker -->
<script type="text/javascript" src="//cdn.jsdelivr.net/bootstrap.daterangepicker/1/daterangepicker.js"></script>
<link rel="stylesheet" type="text/css" href="//cdn.jsdelivr.net/bootstrap.daterangepicker/1/daterangepicker-bs3.css" />
<input type="text" name="daterange" value="01/01/2015 - 01/31/2015" />
您可以在此处下载这些脚本:
http://www.jsdelivr.com/