DOMChildNode
interface DOMChildNode (View source)
Properties
DOMElement|null read-only | $previousElementSibling | ||
DOMElement|null read-only | $nextElementSibling |
Methods
void
replaceWith(DOMNode|string|null ...$nodes)
Replace current node with new node(s), a combination of {DOMChildNode::remove()} + {DOMChildNode::append()}.
Details
void
remove()
Since: 8.0
Acts as a simpler version of {DOMNode
void
before(DOMNode|string|null ...$nodes)
Since: 8.0
Add passed node(s) before the current node
void
after(DOMNode|string|null ...$nodes)
Since: 8.0
Add passed node(s) after the current node
void
replaceWith(DOMNode|string|null ...$nodes)
Since: 8.0
Replace current node with new node(s), a combination of {DOMChildNode::remove()} + {DOMChildNode::append()}.