摘要: 使用教程Create session cookie: $.cookie('the_cookie', 'the_value');Create expiring cookie, 7 days from then: $.cookie('the_cookie', 'the_value', { expires: 7 });Create expiring cookie, valid across entire site: $.cookie('the_cookie', 'the_value', { expires 阅读全文
posted @ 2013-01-09 22:34 yokoboy 阅读(155) 评论(0) 推荐(0) 编辑
摘要: #region 使您可以在使用 Visual Studio 代码编辑器的大纲显示功能时指定可展开或折叠的代码块。例如:#region MyClass definitionpublic class MyClass { static void Main() { }}#endregion1. #region 块必须以 #endregion 指令终止。2. #region 块不能与 #if 块重叠。但是,可以将 #region 块嵌套在 #if 块内,或将 #if 块嵌套在 #region 块内。以上来自:http://msdn.microsoft.com/zh-cn/librar... 阅读全文
posted @ 2012-12-11 17:41 yokoboy 阅读(6104) 评论(2) 推荐(0) 编辑
摘要: 代码是这样的<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head> <meta http-equiv="Content-Type" content="text/html; chars 阅读全文
posted @ 2012-12-07 18:43 yokoboy 阅读(227) 评论(0) 推荐(0) 编辑
摘要: <script type="text/javascript"> $(document).ready(function () { if ($.browser.mozilla && $.browser.version >= "1.8") { alert("火狐"); } if ($.browser.safari) { alert("safari"); } if ($.browser.chrome) { ... 阅读全文
posted @ 2012-12-07 17:04 yokoboy 阅读(416) 评论(0) 推荐(0) 编辑
摘要: 1. 选择自己 <div id="wai"> 外部 <span> span wai</span> <div id="nei"> 内部 <span>span nei</span> </div> </div> $("#wai").html();他只是选择了 { 外部 <span> span wai</span> <div id="nei"> 内部 <span>span nei& 阅读全文
posted @ 2012-12-07 16:48 yokoboy 阅读(433) 评论(0) 推荐(0) 编辑
摘要: 这里并没有使用js来渲染easyUI组件,通过HTML来实现。<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head> <title></title> <script src="e 阅读全文
posted @ 2012-12-07 11:43 yokoboy 阅读(26520) 评论(0) 推荐(0) 编辑
摘要: 1. 使用 data-options 来初始化属性。data-options是jQuery Easyui 最近两个版本才加上的一个特殊属性。通过这个属性,我们可以对easyui组件的实例化可以完全写入到html中,例如:<div class="easyui-dialog" style="width:400px;height:200px" data-options="title:'My Dialog',collapsible:true,iconCls:'icon-ok',onOpen:function(){} 阅读全文
posted @ 2012-12-06 20:35 yokoboy 阅读(81950) 评论(8) 推荐(7) 编辑
摘要: 1 package bin.ykb; 2 3 import java.io.File; 4 import java.io.FileNotFoundException; 5 import java.util.Scanner; 6 7 public class Demo1 { 8 9 /**10 * 具体看JDK文档11 * 12 * @author yokoboy13 * @throws FileNotFoundException14 */15 public static void readFile() throws Fi... 阅读全文
posted @ 2012-07-25 15:41 yokoboy 阅读(457) 评论(0) 推荐(0) 编辑
摘要: C语言的程序猿们肯定会对这个新特性倍感亲切。 输出一个加法算式,1.5版本以前的写法是: int x = 5; int y = 7; int nSum = x + y; System.out.println(x + " + " + y + " = " + nSum); 而在1.5版本中可以写为:System.out.printf("%d + %d = %d\n", x, y, nSum);以上两种写法的输出结构是一样的,即“5 + 7 = 12”。 printf还可以提供更为灵活、强大的输出功能,比如限定按照两位整数的形式输出,可以写 阅读全文
posted @ 2012-07-25 14:15 yokoboy 阅读(217) 评论(0) 推荐(0) 编辑
摘要: 1 class MyEnum { 2 3 private MyEnum() { 4 } 5 6 public static final MyEnum e1 = new MyEnum(); 7 public static final MyEnum e2 = new MyEnum(); 8 public static final MyEnum e3 = new MyEnum(); 9 }10 11 public class LikeEnum {12 13 public static void main(String[] args) {14 ... 阅读全文
posted @ 2012-07-25 13:49 yokoboy 阅读(744) 评论(0) 推荐(0) 编辑
yokoboy