title: Can not load xml file in javascript
body: <p>I am trying to load an xml file that is on my local system. But I always get Network_err. I do the following.</p>
  
  <pre><code>function LoadXmlDoc(dName)
  {
      var xhttp;
      if(window.XMLHttpRequest)
      {
          xhttp = new XMLHttpRequest();
      }
      else
      {
          xhttp = new ActiveXObject("Microsoft.XMLHTTP");
      }
      try
      {       
          xhttp.open("GET", "file.xml", false);
          xhttp.send();
      }
      catch(e)
      {       
          window.alert("Unable to load the requested file.");
          return;
      }
      return xhttp.responseXML;
  }
  </code></pre>
  
  <p>How can I load an xml file that is on my system. all files are in same folder on my pc. Thanks</p>