- simplexml_load_string: documentation ( source)
<?php
$xml=simplexml_load_string(<<<XML
<?xml version="1.0"?>
<root>
<element>
<feed id="9">
<title>test</title>
<table>feeds</table>
<link/>
<feed_type>API</feed_type>
<affiliate/>
<mwst>ja</mwst>
<tld>DE</tld>
<query/>
</feed>
<feed id="10">
<title>test</title>
<table>feeds</table>
<link/>
<feed_type>API</feed_type>
<affiliate/>
<mwst>ja</mwst>
<tld>DE</tld>
<query/>
</feed>
</element>
</root>
XML
);
unset($xml->xpath('element/feed[@id="10"]')[0]->{0});
echo $xml->asXML();