1. 首页
  2. 跨平台
  3. Cordova
  4. JS.GetAllChild(elementdeepcondition)使用介绍

JS.GetAllChild(elementdeepcondition)使用介绍

上传者: 2020-12-13 09:33:54上传 PDF文件 15.71KB 热度 8次
代码如下: window.GetAllChild = function (element, deep, condition) { if (!!!deep) { deep = 1; } if (!!!condition || condition == ”) { condition = ‘1==1’; } deep–; if (!!!element || !!!element.childNodes || element.childNodes.length <= 0) { return []; } var result = new Array(); for (var i = 0; i <
下载地址
用户评论