本文介绍了添加runat =" server"时,Daterangepicker在ASP.NET中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在asp.net中使用jquery daterangepicker控件但它不能正常工作
我尝试了什么:
我的代码:
< pre lang =c#>
< div class =col-md-6 xdisplay_inputx form-group has-feedback>
< input type =textrunat = server class =form-control has-feedback-leftid =single_cal1placeholder =First Namearia-describedby =inputSuccess2Status> ;
< script type =text / javascript>
$(document).ready(function(){
$(function(){
$(#single_cal1)。daterangepicker();
} );
});
< / script>
< span class =fa fa-calendar-o form-control-feedback leftaria-hidden =true>< / span>
< span id =inputSuccess2Statusclass =sr-only>(成功)< / span>
< / div>
function daterangepicker Bootstrap
$(' #single_cal1')。daterangepicker({
singleDatePicker: true ,
singleClasses: picker_1,
locale:{
format:' DD / MM / YYYY',
}
}, function (开头,结尾,标签){
console .log(start.toISOString(),end.toISOString(),label);
});
帮助我!!
解决方案
I using jquery daterangepicker control in asp.net but it not working
What I have tried:
My code: <pre lang="c#"> <div class="col-md-6 xdisplay_inputx form-group has-feedback"> <input type="text" runat=server class="form-control has-feedback-left" id="single_cal1" placeholder="First Name" aria-describedby="inputSuccess2Status"> <script type="text/javascript"> $(document).ready(function () { $(function () { $("#single_cal1").daterangepicker(); }); }); </script> <span class="fa fa-calendar-o form-control-feedback left" aria-hidden="true"></span> <span id="inputSuccess2Status" class="sr-only">(success)</span> </div>
function daterangepicker Bootstrap
$('#single_cal1').daterangepicker({ singleDatePicker: true, singleClasses: "picker_1", locale: { format: 'DD/MM/YYYY', } }, function(start, end, label) { console.log(start.toISOString(), end.toISOString(), label); });
Help me !!
解决方案
这篇关于添加runat =" server"时,Daterangepicker在ASP.NET中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!