我正在使用document.querySelectorAll()
我知道这[id^='id1']
将匹配以id1开头的所有id。
[id$='textBox']
将匹配所有以textBox结尾的ID。
但我想将两者结合起来。这是我想做的事情:
document.querySelectorAll('[id should shart with id1 and ending with textBox]')
Run Code Online (Sandbox Code Playgroud)
这可能吗?