PHP function supposed to return a DOMElement object always returns NULL
I’m trying to write a function that will receive a DOMElement object, perform some seeking operations within its descendants and then return the DOMElement corresponding to the wanted parameters.
How to count children in DOMNodeList? PHP
I am trying to count children of a DOMNode
. It appears to give wrong results when I use count
vs traversing or the ->length
property. As if text nodes are not counted.