⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 test2.js

📁 《征服Ajax》原书的例题源码
💻 JS
字号:
function test1() {
	var _test = "test";
	this.p1 = "p1";
	this.p2 = "p2";
	this.f1 = function() {
		alert("f1");
	}
	this.f2 = function() {
		alert("f2");
	}
}

test1.staticProp = "staticProp test";
test1.staticMethod = function() {
	alert(test1.staticProp);
}

test1.prototype.prop2 = "prop2";
test1.prototype.method2 = function() {
	alert(this.prop2);
}

var t = new test1();
t.method2();

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -