Warning while loading XML feed from other site
<pre><code>$xmlDoc = new DOMDocument();

$url = 'http://domain.com/london/rss';

$key='item';

if($xmlDoc-&gt;load($url))

{
    $items = $xmlDoc-&gt;getElementsByTagName($key);
    if($items)
        {
            for($i=0; $i&lt;$items-&gt;length; $i++)
                {
                    foreach($items-&gt;item($i)-&gt;childNodes as $childnode){
                        echo $childnode-&gt;nodeValue;
                    }
                }
        }
}
</code></pre>

<p>I use the above code to grab the details from the remote xml, but while load the xml it displays the below warning message in the <strong>client server</strong>. </p>

<p><strong>Same code is working fine in my local machine and other servers.</strong></p>

<pre><code>Warning: DOMDocument::load() [domdocument.load]: Document is empty in http://domain.com/london/rss, line: 1 in /var/sites/d/mydomain.com/public_html/loadXML.php on line 5

Warning: DOMDocument::load() [domdocument.load]: Start tag expected, '&lt;' not found in http://domain.com/london/rss, line: 1 in /var/sites/d/mydomain.com/public_html/loadXML.php on line 5
</code></pre>
