我在 html 中给了一些选项一些值,我想将这些值保存在 js var 中,我写了以下行,但它没有用
for (let node of document.getElementsByClassName('op.e.target.value')) {
values.push(node.value);
}
(其中 op 是赋予所有值的类)
我在 html 中给了一些选项一些值,我想将这些值保存在 js var 中,我写了以下行,但它没有用
for (let node of document.getElementsByClassName('op.e.target.value')) {
values.push(node.value);
}
(其中 op 是赋予所有值的类)