OiO.lk Blog PHP DOM Xpath: select content between (invalid) used of double and tags
PHP

DOM Xpath: select content between (invalid) used of double and tags


I can’t select the content of articles (that where made in Craft), I persume because of the invalid use by my former websitebuilder of double / nested P-tags in the HTML.

To clarify the code of the page:

<div class="col-sm-1"></div> <div class="col-sm-5"> <h2>Title</h2> <p><p>TEXT I WANT TO SELECT</p></p>

I have tried these selection methods:

//p
//p/*[first()]
//p[contains(text(),'')
//p[contains(text(),'')]//p



You need to sign in to view this answers

Exit mobile version