0

My XML has that content:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<education:education xmlns:address="http://www.orcid.org/ns/address" xmlns:email="http://www.orcid.org/ns/email" xmlns:history="http://www.orcid.org/ns/history" xmlns:employment="http://www.orcid.org/ns/employment" xmlns:education="http://www.orcid.org/ns/education" xmlns:other-name="http://www.orcid.org/ns/other-name" xmlns:deprecated="http://www.orcid.org/ns/deprecated" xmlns:funding="http://www.orcid.org/ns/funding" xmlns:research-resource="http://www.orcid.org/ns/research-resource" xmlns:service="http://www.orcid.org/ns/service" xmlns:researcher-url="http://www.orcid.org/ns/researcher-url" xmlns:distinction="http://www.orcid.org/ns/distinction" xmlns:internal="http://www.orcid.org/ns/internal" xmlns:membership="http://www.orcid.org/ns/membership" xmlns:person="http://www.orcid.org/ns/person" xmlns:personal-details="http://www.orcid.org/ns/personal-details" xmlns:bulk="http://www.orcid.org/ns/bulk" xmlns:common="http://www.orcid.org/ns/common" xmlns:record="http://www.orcid.org/ns/record" xmlns:keyword="http://www.orcid.org/ns/keyword" xmlns:activities="http://www.orcid.org/ns/activities" xmlns:qualification="http://www.orcid.org/ns/qualification" xmlns:external-identifier="http://www.orcid.org/ns/external-identifier" xmlns:error="http://www.orcid.org/ns/error" xmlns:preferences="http://www.orcid.org/ns/preferences" xmlns:invited-position="http://www.orcid.org/ns/invited-position" xmlns:work="http://www.orcid.org/ns/work" xmlns:peer-review="http://www.orcid.org/ns/peer-review" put-code="2205086" path="/0000-0001-5010-5001/education/2205086" display-index="0" visibility="public">
    <common:created-date>2016-09-01T19:20:47.076Z</common:created-date>
    <common:last-modified-date>2016-09-01T19:20:47.076Z</common:last-modified-date>
    <common:source>
        <common:source-orcid>
            <common:uri>https://orcid.org/0000-0001-5010-5001</common:uri>
            <common:path>0000-0001-5010-5001</common:path>
            <common:host>orcid.org</common:host>
        </common:source-orcid>
        <common:source-name>Quang Nguyen</common:source-name>
    </common:source>
    <common:end-date>
        <common:year>2012</common:year>
        <common:month>05</common:month>
    </common:end-date>
    <common:organization>
        <common:name>University of Virginia</common:name>
        <common:address>
            <common:city>Charlottesville</common:city>
            <common:region>Virginia</common:region>
            <common:country>US</common:country>
        </common:address>
    </common:organization>
</education:education>

WHen I try to use:

simplexml_load_file($file);
print_r($xml);

It does not return any nodes.

Looks like the problem is the use of ":" like education:education

Any way to solve that ?

2

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.