Given a xml
<xml>
<![CDATA[<myNode>aaa</myNode><anotherNode>bbb</anotherNode>]]>
</xml>
How to access a node inside myNode (that it’s inside a CDATA) using Simple HTML DOM?
Is it possible, or maybe I should change to another lib?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
CDATA blocks will be ignored by any parser, so any xml nodes that you have in CDATA blocks will not be queryable unless you parse the CDATA text as well. In other words:
Having said all of that, why in the world do you have full xml text inside of CDATA blocks? Sounds like extremely lazy escaping to me.