KendoUI系列:Window
1、基本使用
<link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.common.min.css")" rel="stylesheet" type="text/css" />
<link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.default.min.css")" rel="stylesheet" type="text/css" />
<script src="@Url.Content("~/Scripts/kendo/2014.1.318/jquery.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/kendo/2014.1.318/kendo.web.min.js")" type="text/javascript"></script>
<div id="Login" style="display: none;">
<table>
<tr>
<td>UserName:</td>
<td><input type="text" /></td>
</tr>
<tr>
<td>Password:</td>
<td><input type="password" /></td>
</tr>
</table>
</div>
<script type="text/javascript">
$(function () {
$("#Login").kendoWindow({
title: "Title",
width: 500,
height: 300,
actions: [
"Pin",
"Minimize",
"Maximize",
"Close"
],
modal: true
}); $("#Login").data("kendoWindow").title("User Login").center().open();
});
</script>
效果预览:

2、自定义动作
<script type="text/javascript">
$(function () {
$("#window").kendoWindow({
title: "Title",
width: 500,
height: 300,
actions: [
"Custom",
"Minimize",
"Maximize",
"Close"
],
modal: true
}); $("#window").data("kendoWindow").center().wrapper.find(".k-i-custom").click(function (e) {
alert("Customizing Action");
e.preventDefault();
});
});
</script>
效果预览:

3、异步加载内容
<div id="window" style="display: none;"></div>
<script type="text/javascript">
$(function () {
$("#window").kendoWindow({
title: "Title",
width: 500,
height: 300,
content: "/Window/AjaxContent.html",
modal: true
}); $("#window").data("kendoWindow").center().open();
});
</script>
4、常用事件
<script type="text/javascript">
$(function () {
var onClose = function () {
alert("Close");
}
var onOpen = function () {
alert("Open");
}
var onRefresh = function () {
alert("Refresh");
}
$("#window").kendoWindow({
title: "Title",
width: 500,
height: 300,
actions:["Refresh","Close"],
content: "/Window/AjaxContent",
open: onOpen,
close: onClose,
refresh:onRefresh,
modal: true
}); $("#window").data("kendoWindow").center().open();
});
</script>
5、参考资料
http://demos.telerik.com/kendo-ui/window/index
KendoUI系列:Window的更多相关文章
- [WPF系列] window自定义
效果图: 源码下载 SourceCode 参考 Disabling or hiding the minimize, maximize or close button of a WPF ...
- KendoUI系列:MultiSelect
1.基本使用 1>.创建Input <link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.common. ...
- KendoUI系列:DatePicker
1.基本使用 <link href="@Url.Content("~/C ontent/kendo/2014.1.318/kendo.common.min.css" ...
- KendoUI系列:DropDownList
1.基本使用 1>.创建Input <input id="dropDownList" /> <link href="@Url.Content(&q ...
- [转]KendoUI系列:Grid
本文转自:http://www.cnblogs.com/libingql/p/3774879.html 1.基本使用 <div id="grid"></div&g ...
- KendoUI系列:TreeView
1.加载本地数据 <link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.common.min.css" ...
- KendoUI系列:TabStrip
<link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.common.min.css")" ...
- KendoUI系列:PanelBar
<link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.common.min.css")" ...
- KendoUI系列:AutoComplete
1.基本使用 <link href="@Url.Content("~/C ontent/kendo/2014.1.318/kendo.common.min.css" ...
随机推荐
- C#匿名函数的坑
在for循环中catch索引 for (int i = 0; i < n; i++) { foo(() =>{ if (i == x) //这里的i始终都是最后一个... { //bala ...
- CSS伪类选择器
一.CSS伪类选择器用于给某些选择器添加效果语法规则:选择器:伪选择器例:a:link {color: #FF0000} 未访问的链接 a:visited {color: #00FF00} 已访问的链 ...
- 解决VS2010子目录中的.cpp文件引用上一级目录的stdafx.h找不到定义的问题
Source目录 |-- stdafx.h |--Util目录 |--Util.h |--Util.cpp 现在的发现Util.cpp各种变量的定义全是红色波浪线,找不到定义,但是却能够编译过 问题就 ...
- 1.iOS直播ijkplayer(第一周)
准备工作: 1.使用的B站的开源框架ijkplayer ,下载地址: https://github.com/Bilibili/ijkplayer ijkplayer 是一个基于 ffplay 的轻量级 ...
- 无法导入以下密钥文件: xxxx.pfx,该密钥文件可能受密码保护 的解决方案
无法导入以下密钥文件: xxxx.pfx,该密钥文件可能受密码保护.若要更正此问题,请尝试再次导入证书,或手动将证书安装到具有以下密钥容器名称的强名称 CSP: VS_KEY_A5A29909FF6D ...
- TestNG参数化测试【转】
原文:http://www.yiibai.com/testng/20130916303.html 在TestNG的另一个有趣的功能是参数测试.在大多数情况下,你会遇到这样一个场景,业务逻辑需要一个巨大 ...
- JavaScript 基础第二天
一.前言 感觉昨天的内容确实是有点细碎.复杂.感觉是没有书上写的那么的细致而且有导入性,但是我还是喜欢这样只说干货.今天的内容将继续接着昨天最后的内容JS中的语言结构继续讲解并且重点讲解一下其中的内容 ...
- 可在广域网部署运行的QQ高仿版 -- GG叽叽V3.5,增加自拍头像功能、细节优化(源码)
距离上次发版本(GG叽叽V3.4,增加系统设置.最近联系人.群功能)又有1个月了,在这个月内,由于空闲时间不是很多,所以,GG增加的主要功能只是拍照并设定其为自己头像.修改密码.删除好友.以及一些bu ...
- 作业二:Github注册过程
第一步.打开Github官网https://github.com/ ,在相应位置填写注册名.注册邮箱.注册密码完成后点击注册. 第二步.这时会弹出一个界面,让你选择你的私人计划(personal pl ...
- Entity Framework 5.0系列之EF概览
概述 在开发面向数据的软件时我们常常为了解决业务问题实体.关系和逻辑构建模型而费尽心机,ORM的产生为我们提供了一种优雅的解决方案.ADO.NET Entity Framework是.NET开发中一种 ...