List all the columns in a table
sql - How do I list all the columns in a table? - Stack Overflow
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced]
"NoNetCrawling"=dword:00000001
Youtube Popup Player
Youtube Popup Player
browser.link.open_newwindow.restriction
值:整數 (Integer)
新連結開啟於分頁或新視窗
//不建議使用 | |
//new Object | |
var person = new Object(); | |
person.name = 'Tom'; | |
person.age = 25; | |
person.sayHi = function() { | |
console.log('Hi, I am ' + this.name + '.'); | |
}; | |
//Factory Paradigm | |
function createPerson(name, age) { | |
var o = new Object(); | |
o.name = name; | |
o.age = age; | |
o.sayHi = function() { | |
console.log('Hi, I am ' + o.name + '.'); | |
}; | |
return o; | |
} | |
var person1 = createPerson('Tom', 20); | |
var person2 = createPerson('Joe', 21); | |
//如有共用的方法,建議加在prototype中 | |
//Object Literal | |
var person = { | |
name: 'Tom', | |
age: 25, | |
sayHi: function() { | |
console.log('Hi, I am ' + this.name + '.'); | |
} | |
}; | |
//Constructor Paradigm | |
function Person(name, age) { | |
this.name = name; | |
this.age = age; | |
this.sayHi = function() { | |
console.log('Hi, I am ' + this.name + '.'); | |
}; | |
} | |
var person1 = new Person('Tom', 20); | |
var person2 = new Person('Joe', 21); | |
//Hybrid Constructor / Prototype Paradigm | |
function Person(name, age) { | |
this.name = name; | |
this.age = age; | |
} | |
Person.prototype.sayHi = function() { | |
console.log('Hi, I am ' + this.name + '.'); | |
}; |
[1, 2, 3, 4].forEach(console.log); | |
/* | |
1 0 [ 1, 2, 3, 4 ] | |
2 1 [ 1, 2, 3, 4 ] | |
3 2 [ 1, 2, 3, 4 ] | |
4 3 [ 1, 2, 3, 4 ] | |
*/ | |
[1, 2, 3, 4].forEach(function(item, index, array) { | |
console.log(); | |
}); | |
/* | |
1 | |
2 | |
3 | |
4 | |
*/ |
every()--------在陳例的每個元素上運行給定函數,如果給定函數對每個項都返回true,則返回true
filter()---------在陣列的每個元素上運行給定函數,並返回包含令給定函數返回true的那些元素
forEach()------在陣列的每個元素上運行給定函數,該方法沒有返回值
map()---------在陣列的每個元素上運行給定函數並返回每次給定函數的返回值組成的陣列
some()--------在陣列的每個元素上運行給定函數,如果給定函數在任意一個元素上返回true,則返回true
javascript: (function () {
function R(a) {
ona = "on" + a;
if (window.addEventListener) window.addEventListener(a, function (e) {
for (var n = e.originalTarget; n; n = n.parentNode) n[ona] = null;
}, true);
window[ona] = null;
document[ona] = null;
if (document.body) document.body[ona] = null;
}
function userSelect() {
var css = document.createElement("style");
css.type = "text/css";
document.getElementsByTagName("head")[0].appendChild(css);
css.innerHTML = "*{-moz-user-select:text!important}";
}
R("contextmenu");
R("click");
R("mousedown");
R("mouseup");
R("selectstart");
userSelect();
})()