XPath does not extract HTML as part of the content

I parse the web page using xPath and retrieving the contents of the div element, it skips the HTML contained in that div element. How to make it get all the contents of a div element with HTML enabled?

0
source share
1 answer

Using

someExprSelectingtheDiv/node()

This selects all the child nodes (markup and text) divselected in the first step of positioning.

Do not work with the value string()for any selected element, because these are only the concatenated (in the order of the document order) descendants of this element.

, node -set - node ( ) node -set.

XPath.

0

Source: https://habr.com/ru/post/1762591/


All Articles