firstElementChild doesn't work in Internet Explorer 7…what are my options?

后端 未结 3 784
眼角桃花
眼角桃花 2021-02-14 17:21

Consider the JavaScript below:

var v;
if (this.children.length > 0) {
    v = this.firstElementChild.value;
}

This works in modern versions

3条回答
提交回复
热议问题