摘要: Tool->General Options->Dialog取消勾选Name to Code mirroring反之,要同步则勾选 阅读全文
posted @ 2011-12-01 13:51 人来人往 阅读(363) 评论(0) 推荐(0) 编辑
摘要: 有些页面样式不规范,没有写在一个class里,例如:<div id="show" style="width:100px; padding-top:10px; font-size:12px;"></div>这种情况下清空style可以removeAttr()方法移除style属性来实现$("#show").removeAttr("style"); //ie,ff均支持$("#show").attr("style",""); //ff支 阅读全文
posted @ 2011-11-29 17:36 人来人往 阅读(149743) 评论(0) 推荐(4) 编辑
摘要: 获取iframe内部对象需先调用contents()方法eg:清空所有iframe对象内部body为空 $(".uEditorIframe").each(function(i, n) { //uEditorIframe iframe class $(n).contents().find("body").html(''); }); 一般地:$("#iframeId").contents().find("#domId") 阅读全文
posted @ 2011-11-25 15:58 人来人往 阅读(1384) 评论(0) 推荐(0) 编辑
摘要: http://www.upian.com/upiansource/ueditor/en 阅读全文
posted @ 2011-11-23 11:39 人来人往 阅读(255) 评论(0) 推荐(0) 编辑
摘要: -- =============================================-- Author: -- Create date: -- Description: 根据下标(0开始),返回split分割后字符串,越界返回空字符串-- eg:SELECT dbo.Split_GetByIndex('w1,w2,,,,w,w,ew',',',1)-- =============================================CREATE FUNCTION [dbo].[Split_GetByIndex]( @SplitStr NVA 阅读全文
posted @ 2011-11-16 09:46 人来人往 阅读(1660) 评论(0) 推荐(0) 编辑
摘要: 原理很简单,用反射获返回实体的属性的数组循环输出属性名和值,拼接Json格式字符串返回(转义掉'\','"'影响Json格式的字符)\ -> \\" -> \"using System.Reflection; /// <summary> /// /// </summary> /// <param name="obj">要转换的实体对象</param> /// <returns></returns> public string En 阅读全文
posted @ 2011-10-13 17:40 人来人往 阅读(7989) 评论(0) 推荐(0) 编辑
摘要: List<T>下的条件Find,FindAll等条件过滤方法需要指定一个用于制定搜索条件的委托才能使用即通过委托告诉其过滤条件根据MSDN的例子://定义一个 Book类型的List集合private static List<Book> Books = new List<Book>();//根据委托条件返回符合条件的记录List<Book> result = Books.Find(delegate(Book bk){ DateTime year2001 = new DateTime(2001,01,01); return bk.Publish_d 阅读全文
posted @ 2011-09-23 15:11 人来人往 阅读(4583) 评论(0) 推荐(0) 编辑
摘要: 1.上下合并(列合并) $.fn.MergeColumns = function() { return this.each(function() { for (var i = $(this).find('tr:first td').size() - 1; i >= 0; i--) { //获取表格td的数量进行循环 var s = null; var prevTd = null; $(this).find('tr... 阅读全文
posted @ 2011-09-22 15:18 人来人往 阅读(487) 评论(0) 推荐(0) 编辑
摘要: /// <summary> /// DataTable to json /// </summary> /// <param name="jsonName">返回json的名称</param> /// <param name="dt">转换成json的表</param> /// <returns></returns> public static string DataTableToJson(string jsonName, System.Data.DataTab 阅读全文
posted @ 2011-09-22 11:52 人来人往 阅读(507) 评论(0) 推荐(0) 编辑
摘要: var regDate = /^(?:(?!0000)[0-9]{4}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1[0-9]|2[0-8])|(?:0[13-9]|1[0-2])-(?:29|30)|(?:0[13578]|1[02])-31)|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)-02-29)$/; 阅读全文
posted @ 2011-09-01 15:26 人来人往 阅读(884) 评论(0) 推荐(0) 编辑