Re: XMLHttpRequest overrideMimeType question..
Lucky <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.xml |
|---|---|
| Organization | Cox Communications |
| Message-ID | <Pktdf.5053$om5.1782@dukeread04> |
Martin Honnen wrote:
>
>
> Lucky wrote:
>
>
>> have seen the mass use of overrideMimeType('text/xml') when using the
>> XMLHttpRequest object.
>>
>> I would really like to know WHY this seems to be some magic "band-aid"
>> for some peoples code, esp when they say it fixes many calls to even
>> HTML pages, that they would possibly never be a "well-formed"
>> XMLDocument??
>
>
> That band aid is usually not necessary if people have set up their HTTP
> servers to serve static or dynamically created XML documents with a
> known XML Content-Type like application/xml or text/xml.
> But an XHTML 1.0 document can be served as text/html and then
> XMLHttpRequest would not parse it as XML and there it would help to use
> overrideMimeType to get XMLHttpRequest to parse the response sent as
> text/html as XML by calling overrideMimeType('application/xml') or even
> ovverideMimeType('application/xhtml+xml').
>
> I don't think overrideMimeType will help in any way to parse HTML tag
> soup successfully with an XML parser.
>
>
they were using for a tag soup instance, and never touching any
responseXML, etc. but, it is a general thought among massed that they
must apply that setting for EVERYTHING?? which baffled me, perhaps some
bug out there??
and what you state about it not helping a tag soup was my thoughts
exactly??