JavaScript二维数组的使用及删除指定元素
JavaScript中是没有二维数组的
那么使用的时候,只有自己构造二维数组
首先定义一个一维数组
var picArrList=new Array(); //定义一维数组
var sectionindex= 2; //或者其它任意序列号都可以,这里只是随便举个例子
if(!picArrList[sectionindex]) picArrList[sectionindex] = new Array();
var picindex = picArrList[sectionindex].length;
<pre class="html" name="code">alert (picArrList[sectionindex][1]);
声明:该文观点仅代表作者本人,入门客AI创业平台信息发布平台仅提供信息存储空间服务,如有疑问请联系rumenke@qq.com。
- 上一篇: php定义二维数组以及和JavaScript传递json数据
- 下一篇:没有了