title: How to parse a XML file stored in my google drive but which stands out as a html type?
body: <p>How to parse a XML file stored in my google drive but which stands out as a html type ?!</p>
  
  <p>I save on my google Drive cloud a copie of an xml of the source: <a href="http://api.allocine.fr/rest/v3/movie?media=mp4-lc&amp;partner=YW5kcm9pZC12Mg&amp;profile=large&amp;version=2&amp;code=265621" rel="nofollow noreferrer">http://api.allocine.fr/rest/v3/movie?media=mp4-lc&amp;partner=YW5kcm9pZC12Mg&amp;profile=large&amp;version=2&amp;code=265621</a>
   I can parsing the source but i cant'xml parsing the copie that look like a html type !!
    i have parsing error  like:  The element type "meta" must be terminated by the matching end-tag ""
     or Element type "a.length" must be followed by either attribute specifications, ">" or "/>"
   I shared it on <a href="https://drive.google.com/file/d/16kJ5Nko-waVb8s2T12LaTEKaFY01603n/view?usp=sharing" rel="nofollow noreferrer">https://drive.google.com/file/d/16kJ5Nko-waVb8s2T12LaTEKaFY01603n/view?usp=sharing</a> to give you an access and test my script.
   I know that i can using cacheService and it works but for have other control of the buffering i woud try this way</p>
  
  <pre><code>function xmlParsingXmlStoreOnGoogleDrive(){
       //So , this is the original xml that is good parsed
   var fetched=UrlFetchApp.fetch("http://api.allocine.fr/rest/v3/movie?media=mp4-lc&amp;partner=YW5kcm9pZC12Mg&amp;profile=large&amp;version=2&amp;code=265621")
   var blob=fetched.getBlob();
   var getAs=blob.getAs("text/xml")
   var data=getAs.getDataAsString("UTF-8")
   Logger.log(data.substring(1,350)); // substring to not saturate the debug display this expected code XML:
   /*
      ?xml version="1.0" encoding="utf-8"?&gt;
      &lt;!-- Copyright © 2019 AlloCiné --&gt;
      &lt;movie code="265621" xmlns="http://www.allocine.net/v6/ns/"&gt;
      &lt;movieType code="4002"&gt;Long-métrage&lt;/movieType&gt;
      &lt;originalTitle&gt;Mise à jour sur Google play&lt;/originalTitle&gt;
      &lt;title&gt;Mise à jour sur Google play&lt;/title&gt;
      &lt;keywords&gt;Portrait of a Lady on Fire &lt;/keywords&gt;
   */
   var xmlDocument=XmlService.parse(data);
   var root=xmlDocument.getRootElement();
   var keywords=root.getChild("keywords",root.getNamespace()).getText();
   Logger.log(keywords);  // Display the expected result :"Portrait of a Lady on Fire "
  
   // And this my copie of the original xml, that i can't parsing
   var fetched=UrlFetchApp.fetch("https://drive.google.com/file/d/1K3-9dHy-h0UoOOY5jYfiSoYPezSi55h1/view?usp=sharing")
   var blob=fetched.getBlob();
   var getAs=blob.getAs("text/xml")
   var data=getAs.getDataAsString("UTF-8")
   Logger.log(data.substring(1,350)); // substring to not saturate the debug display this non expected code HTML !:
   /*
     !DOCTYPE html&gt;&lt;html&gt;&lt;head&gt;&lt;meta name="google" content="notranslate"&gt;&lt;meta http-equiv="X-UA-Compatible" content="IE=edge;"&gt;
     &lt;style&gt;@font-face{font-family:'Roboto';font-style:italic;font-weight:400;src:local('Roboto Italic'),local('Roboto-Italic'),
     url(//fonts.gstatic.com/s/roboto/v18/KFOkCnqEu92Fr1Mu51xIIzc.ttf)format('truetype');}@font-face{font-fam......
   */
   var xmlDocument=XmlService.parse(data); // ABORT WITH THE ERROR: Element type "a.length" must be followed by either attribute specifications, "&gt;" or "/&gt;"
   var root=xmlDocument.getRootElement();
   var keywords=root.getChild("keywords",root.getNamespace()).getText();
   Logger.log(keywords);
  }
  </code></pre>
  
  <p>I read on this similar ask :<a href="https://stackoverflow.com/questions/35873647/parse-xml-file-which-is-stored-on-googledrive-with-google-app-script">Parse XML file (which is stored on GoogleDrive) with Google app script</a></p>
  
  <p>that "Unfortunately we can't directly get xml files in the google drive" !! 
  Is it right and would that simply mean that I can not realize my script?</p>