摘要: 主要就是《javascript语言精粹》语言精粹中的内容5.1伪类Function.prototype.method = function(name,func){ this.prototype[name] = func; return this; }var Cat = function(name){ this.name = name; this.saying = "meow";}Cat.prototype = new Mammal();Cat.prototype.purr = function(n){ var i,s = ""; for(i = 0 ; 阅读全文
posted @ 2014-03-25 10:17 星堡a 阅读(1834) 评论(0) 推荐(0) 编辑