Javascript 使用剑道UI-创建日历
这是一个非常基本的问题-如何创建剑道UI控件/如何让剑道小部件显示 我试着用这个来控制日历。 我将js文件复制到一个js文件夹中Javascript 使用剑道UI-创建日历,javascript,kendo-ui,Javascript,Kendo Ui,这是一个非常基本的问题-如何创建剑道UI控件/如何让剑道小部件显示 我试着用这个来控制日历。 我将js文件复制到一个js文件夹中 闵 网 vsdoc 历法 并链接了两个样式文件 当我使用下面的脚本来实例化日历小部件时 <script> $(document).ready(function () { $("#cal").kendoCalendar({ value: new Date(), min: new Da
- 闵
- 网
- vsdoc
- 历法
<script>
$(document).ready(function () {
$("#cal").kendoCalendar({
value: new Date(),
min: new Date(1950, 0, 1),
max: new Date(2049, 11, 31)
});
});
</script>
$(文档).ready(函数(){
$(“#cal”)。肯多卡伦达({
值:新日期(),
最小值:新日期(1950,0,1),
最长:新日期(2049年11月31日)
});
});
但是我在.kendoCalendar()实例化日历时出错
有人能帮我吗
提前感谢。您只需要包括:
<!-- Kendo UI Web styles-->
<link href="styles/kendo.common.min.css" rel="stylesheet" type="text/css"/>
<link href="styles/kendo.default.min.css" rel="stylesheet" type="text/css"/>
<!-- jQuery scripts-->
<script src="js/jquery.min.js" type="text/javascript"></script>
<!-- Kendo UI Web scripts-->
<script src="js/kendo.web.min.js" type="text/javascript"></script>
编辑:使用KendoUI CDN文件完成示例:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8"/>
<title>OnaBai - KendoUI Calendar example</title>
<!-- Kendo UI Web styles-->
<link href="http://cdn.kendostatic.com/2012.3.1114/styles/kendo.common.min.css" rel="stylesheet"/>
<link href="http://cdn.kendostatic.com/2012.3.1114/styles/kendo.default.min.css" rel="stylesheet"/>
<!-- Kendo UI Web scripts-->
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script src="http://cdn.kendostatic.com/2012.3.1114/js/kendo.web.min.js"></script>
<!-- Initialize Form Elements -->
<script type="text/javascript">
$(document).ready(function () {
$("#cal").kendoCalendar({
value: new Date(),
min : new Date(1950, 0, 1),
max : new Date(2049, 11, 31)
});
});
</script>
</head>
<body>
<div id="cal" name="cal"/>
</body>
</html>
OnaBai-KendoUI日历示例
$(文档).ready(函数(){
$(“#cal”)。肯多卡伦达({
值:新日期(),
最小值:新日期(1950,0,1),
最长:新日期(2049年11月31日)
});
});
thx。我确实包含jquery.min.js;我没有把它列出来。我不明白为什么我不能创建日历,但是你能让它运行吗?或者你更喜欢我在这里发布一个完整的HTML和日历吗?不,它仍然会给我一个错误。仅供参考,我正在使用asp.net mvc,但这不重要。请把代码贴出来,我试试看。谢谢你help@Ra.,我添加了一个完整的示例(检查编辑)。按原样去试;如果可行,则更改您的CDN路径;如果可以,请将其转换为ASP.MVC。祝你好运你的代码对我有用。奇怪。我必须分析我的失败的原因。
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8"/>
<title>OnaBai - KendoUI Calendar example</title>
<!-- Kendo UI Web styles-->
<link href="http://cdn.kendostatic.com/2012.3.1114/styles/kendo.common.min.css" rel="stylesheet"/>
<link href="http://cdn.kendostatic.com/2012.3.1114/styles/kendo.default.min.css" rel="stylesheet"/>
<!-- Kendo UI Web scripts-->
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script src="http://cdn.kendostatic.com/2012.3.1114/js/kendo.web.min.js"></script>
<!-- Initialize Form Elements -->
<script type="text/javascript">
$(document).ready(function () {
$("#cal").kendoCalendar({
value: new Date(),
min : new Date(1950, 0, 1),
max : new Date(2049, 11, 31)
});
});
</script>
</head>
<body>
<div id="cal" name="cal"/>
</body>
</html>