js 获取子节点函数 (兼容FF与IE)
摘要:复制代码代码如下:functiongetFirstChild(obj){varresult=obj.firstChild;while(!re...
复制代码 代码如下:
function getFirstChild(obj) {
var result = obj.firstChild;
while (!result.tagName) {
result = result.nextSibling;
}
return result;
}
function getNextChild(obj) {
var result = obj.nextSibling;
while (!result.tagName) {
result = result.nextSibling;
}
return result;
}
【js 获取子节点函数 (兼容FF与IE)】相关文章:
★ 滚动效果
★ js获取变量