I would like to parse the HTML DOM, using PHP;
I have a string PN, and I want to detect the Parrent of the DOM Element where PN has been found as content;
Then, with the Parrent Element found, i need all the Childrens of those Elements;
All the other DOM Elements that are not under the Parrent structure, must be ignored;
this is what i managed to write, but i dont know what to write after $node-> in order to obtain the element (h1,h2,div,span) …