13 if (!Array.prototype.every) {
14 Array.prototype.every =
function(callback) {
15 var len = this.length,
i;
17 for (i = 0; i < len; i++) {
18 if (i in
this && !callback.call(null,
this[i], i)) {
39 if (!Array.prototype.forEach) {
40 Array.prototype.forEach =
function(callback) {
41 var len = this.length,
i;
43 for (i = 0; i < len; i++) {
45 callback.call(null,
this[i], i);
58 if (!String.prototype.ltrim) {
59 String.prototype.ltrim =
function(str) {
60 if (this.indexOf(str) === 0) {
61 return this.substring(str.length);