三者都是一样的,最完整的写法是:$(document).ready(function(){})ready() 函数仅能用于当前文档,因此无需选择器。所以document选择器可以不要,那么就可以写成:$().ready(function(){})最后$的默认事件就是ready,所以,ready也可以 ...
分类:
其他好文 时间:
2016-05-20 17:33:30
阅读次数:
115
Date.prototype.Format = function(fmt) { //author: meizz var o = { "M+" : this.getMonth()+1, //月份 "d+" : this.getDate(), //日 "h+" : this.getHours(), // ...
分类:
其他好文 时间:
2016-05-20 17:30:04
阅读次数:
102
type命令用来显示指定命令的类型,判断给出的指令是内部指令还是外部指令。 命令类型: alias:别名。 keyword:关键字,Shell保留字。 function:函数,Shell函数。 builtin:内建命令,Shell内建命令。 file:文件,磁盘文件,外部命令。 unfound:没有 ...
分类:
系统相关 时间:
2016-05-20 17:25:28
阅读次数:
226
[JavaScript] +function(){} 作用瞎扯在JS中,经常会遇到下面这种 代码, 到底 在 function 前面加一个 一元操作符, 有什么作用呢?作用是 把该函数变成自执行函数+function(){}();这里的加号,可以替换成 ~ , * , + , - , ! 等其他一元... ...
分类:
编程语言 时间:
2016-05-20 14:36:20
阅读次数:
160
//格式化金钱( 9,999.00)function formatCurrency(num) { num = num.toString().replace(/\$|\,/g, ''); if (isNaN(num)) num = "0"; sign = (num == (num = Math.abs ...
分类:
其他好文 时间:
2016-05-20 14:33:30
阅读次数:
198
一、Function.call()函数 1、a.call(b)??; //包含第三点[将.call(b)前面的对象传递给b对象] //很像继承 将a对象(所有)传递给b函数对象????; 2、a.aMethod.call(b)?; //不会覆盖b中的同名方法 将?a的aMethod方法传递给b函数对 ...
分类:
移动开发 时间:
2016-05-20 13:25:59
阅读次数:
214
A class that describes an XML element that is to be a top-level element, i.e., one that can function as an XML document, should be annotated with XmlR ...
分类:
其他好文 时间:
2016-05-20 13:23:51
阅读次数:
224
H-Index Given an array of citations (each citation is a non-negative integer) of a researcher, write a function to compute the researcher's h-index. A ...
分类:
其他好文 时间:
2016-05-20 13:22:48
阅读次数:
123
$.ajax({ url: "请求地址", dataType: "text", type: "GET" data: {}, success: function(data){ $("#id").html(data); }}); ...
分类:
Web程序 时间:
2016-05-20 13:11:17
阅读次数:
152
$(document).ready(function () { $("#zidong3,#zidong1").click(function () { $("#zidong3").css("-webkit-animation", "gira 1s ease-out 1"); $("#zidong3") ...
分类:
Web程序 时间:
2016-05-20 09:54:59
阅读次数:
131