Definição da função
Array.prototype.IndexOf = function (val) {for (var i = 0; i <this.length; i ++) {if (this [i] == val) retornar i; } return -1;}; array.prototype.remove = function (val) {var index = this.indexof (val); if (índice> -1) {this.splice (índice, 1); }}; Array.prototype.insert = function (index, item) {this.splice (index, 0, item);};usar:
MyArray.Remove (i); //Excluir
//renovar
MyArray.Remove (0);
MyArray.insert (0, Eventjson [0]);
//inserir
MyArray.insert (0, Eventjson [0]);
A implementação simples do JavaScript JS acima da adição, exclusão, modificação e pesquisa é todo o conteúdo que compartilho com você. Espero que você possa lhe dar uma referência e espero que você possa apoiar mais o wulin.com.