在我的段落中,我必须得到方括号[]之间的字符串
即
<p id="mytext"> this is my paragraph but I have [code1] and there is another bracket [code2]. </p>
在我的JavaScript上,我遍历了所有字符串,并仅以“ code1”和“ code2”获取数组的结果
先感谢您!
javascript
javascript ×1