I’ve been trying to use SimpleXML, but it doesn’t seem to like XML that looks like this:
<xhtml:div>sample <xhtml:em>italic</xhtml:em> text</xhtml:div>
So what library will handle tags that look like that (have a colon in them)?
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.
Say you have some xml like this.
You can access ’em’ like this:
$xml->children('xhtml', true)->div->em;however, if you want the date field, this:
$xml->children('xhtml', true)->div->date;wont work, because you are stuck in the xhtml namespace.you must execute ‘children’ again to get back to the default namespace: