XMLHttpRequest xml response woes with jQuery 1.4.1, how to force the request response to be processed as plain text?
<p>I'm just playing around with jQuery and trying something that ought be simple, but it just ain't working.</p>

<pre><code>    $(document).ready(function(){
 $.ajax({
  url : 'http://soiduplaan.tallinn.ee/',
  data : {a : 'p.routes', transport_id : 'tram', t : 'xml', l : 'ee'},
  error : function(xhr, stat){
   alert('error'); 
  },
  success : function(data){
   alert('success');
   alert(data);
  }
 });
});
</code></pre>

<p>The snippet is in a test.js file and included in a test.html file which is opened in Firefox (3.6) like file:///C:/test.html and altough 'success' is shown the data is empty and through Firebug the response for XML displays:</p>

<pre><code>X`ML Parsing Error: no element found Location: moz-nullprincipal:{5ac44e50-2cb6-45d1-9cfe-0b999850ecdb} Line Number 1, Column 1:`
</code></pre>

<p>Alternatively I tried that adding</p>

<pre><code>dataType : "text"
</code></pre>

<p>has no effect, the result is still processed as xml (probably because the response has content-type: text/xml; charset=UTF-8).</p>

<p>I'm able to see the response results through Firebug if I set</p>

<pre><code>dataType : "script"
</code></pre>

<p>but then as it isn't actually a valid js script it simply fails, Firebug displays:</p>

<pre><code>    invalid regular expression flag t
&lt;?xml version="1.0" encoding="UTF-8"?&gt;..._days&gt;&lt;types&gt;&lt;type routes="85" city="t
</code></pre>

<p>It gets "better", if do the above request in browser and through "View Source" copy the xml to be validated here <a href="http://www.w3schools.com/Dom/dom_validate.asp" rel="nofollow">http://www.w3schools.com/Dom/dom_validate.asp</a> it displays "no errors found" so why won't it work through xmlhttprequest?</p>

<p>What am I doing wrong?</p>

<p>Would it be possible to somehow force the xmlhttprequest's response to be processed as text/plain?</p>

<p>br,
iges</p>

<p>P.S. I've tired the suggested dataType : "html" option (forgot to mention initially), but the "html" also does not work and in Firebug I can see the same error about parsing/moz-nullprincipal.</p>

<p>Also the service providing the xml data is controlled by a third party to which I do not have access, either there is a way to do this or I'll have to kiss my idea goodbye :(</p>
