I have an xml file with a header like the following:

```
<!ENTITY nbsp   "&#160;"><!-- no-break space = non-breaking space,
                                   U+00A0 ISOnum -->
 <!ENTITY iexcl  "&#161;"><!-- inverted exclamation mark, U+00A1 ISOnum -->
 <!ENTITY cent   "&#162;"><!-- cent sign, U+00A2 ISOnum -->
 <!ENTITY pound  "&#163;"><!-- pound sign, U+00A3 ISOnum -->
 <!ENTITY curren "&#164;"><!-- currency sign, U+00A4 ISOnum -->
 <!ENTITY yen    "&#165;"><!-- yen sign = yuan sign, U+00A5 ISOnum -->
 <!ENTITY brvbar "&#166;"><!-- broken bar = broken vertical bar,
                                   U+00A6 ISOnum -->
 <!ENTITY sect   "&#167;"><!-- section sign, U+00A7 ISOnum -->
 <!ENTITY uml    "&#168;"><!-- diaeresis = spacing diaeresis,
                                   U+00A8 ISOdia -->
 <!ENTITY copy   "&#169;"><!-- copyright sign, U+00A9 ISOnum -->
 <!ENTITY ordf   "&#170;"><!-- feminine ordinal indicator, U+00AA ISOnum -->
 <!ENTITY laquo  "&#171;"><!-- left-pointing double angle quotation mark
                                   = left pointing guillemet, U+00AB ISOnum -->
 <!ENTITY not    "&#172;"><!-- not sign, U+00AC ISOnum -->
 <!ENTITY shy    "&#173;"><!-- soft hyphen = discretionary hyphen,
                                   U+00AD ISOnum -->
 <!ENTITY reg    "&#174;"><!-- registered sign = registered trade mark sign,
                                   U+00AE ISOnum -->
 <!ENTITY macr   "&#175;"><!-- macron = spacing macron = overline
                                   = APL overbar, U+00AF ISOdia -->
 <!ENTITY deg    "&#176;"><!-- degree sign, U+00B0 ISOnum -->
 <!ENTITY plusmn "&#177;"><!-- plus-minus sign = plus-or-minus sign,
                                   U+00B1 ISOnum -->

```

When I try to load it into a dom document, it doesn't seem to save it to file. I think the above code may be causing parsing erros. Is there a way to remove these headers?

This is my php code:

```
$xml = curl_exec($ch);
$srcDom = new DOMDocument;
$srcDom->load($xml);
$xPath = new DOMXPath($srcDom);
foreach ($srcDom->getElementsByTagName('Venue') as $venue) {
    $dstDom = new DOMDocument('1.0', 'utf-8');
    $dstDom->appendChild($dstDom->createElement('EventsPricePoints'));
    $dstDom->documentElement->appendChild($dstDom->importNode($venue, true));

    $allEventsForVenue = $xPath->query(
        sprintf(
            '/Store/EventsPricePoints/Event[VenueID/@ID=%d]',
            $venue->getAttribute('ID')
        )
    );

    foreach ($allEventsForVenue as $event) {
        $dstDom->documentElement->appendChild($dstDom->importNode($event, true));
    }

    $dstDom->formatOutput = true;
    $dstDom->saveXml(sprintf('/var/www/html/venuexml/%d.xml', $venue->getAttribute('ID')));
}

```