File Write permission in php and xml
<pre><code>ob_start();
echo '&lt;'.'?xml version="1.0"?'.'&gt;';
echo '&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;';
echo '&lt;root&gt;';
$hierarchy=$tree-&gt;getArray();
recursiveBuild($hierarchy[0]);
echo '&lt;/root&gt;';
file_put_contents('file.xml', ob_get_contents());
ob_end_clean();

file_put_contents('file.xml', 'w+' ob_get_contents());
</code></pre>

<p>This is not working, its not updating the xml file automatically.</p>
