我有一个Bootstrap Popover,在里面我想有一个内联的datepicker。然而,datepicker被创建,但没有datepicker事件触发。
我也参考了Link 1,Link 2和Link 3,但没有一个适合我。
HTML代码
<div class="container" style="text-align:center;">
<a href="#" data-toggle="popover" data-placement="bottom" id="lnkLaunchDate">
<i class="glyphicon glyphicon-filter" style="color: #000 !important;"></i>
</a>
</div>
<div id="popover-launchDate" class="hide">
<div>
<div id="launchDate" class="grid-filter-datepicker" style="font-size:9px !important"></div>
</div>
</div>
字符串
脚本
$('[data-toggle="popover"]').popover({
html: true,
title: function () {
return "";
},
content: function () {
return $("#popover-launchDate").html();
},
callback: function () {
$('#launchDate').datepicker();
}
}).on('shown.bs.popover', function() {
$('#launchDate').datepicker();
});
$('#launchDate').datepicker();
型
我的demo
我错过什么了吗?任何帮助都将不胜感激。
2条答案
按热度按时间q0qdq0h21#
这是一个使用Bootstrap HTML的简单jQueryUI日历实现
个字符
你可以按照你的设计风格
wi3ka0sx2#
更改脚本代码
字符串