otest.lastChild[0]與otest.lastChild有什么區(qū)別
使用otest.insertBefore(newcode,otest.lastChild),新加入的li標(biāo)簽內(nèi)容“php“輸出在”HTML“前面,而otest.lastChild[0]新加入的li標(biāo)簽內(nèi)容“php“輸出在最后面,為什么呢?
使用otest.insertBefore(newcode,otest.lastChild),新加入的li標(biāo)簽內(nèi)容“php“輸出在”HTML“前面,而otest.lastChild[0]新加入的li標(biāo)簽內(nèi)容“php“輸出在最后面,為什么呢?
2021-03-29
舉報(bào)
2022-05-06
是lastChild[0]還是childNodes[0]?