Thanks, the text2xml function works well, however i've managed to sort
what was causing the problem.

My ajax .ASP page was missing response.ContentType = "text/xml".
Setting this enabled me to get the result as an xml document.

I'm going to keep hold of text2xml as it will definately be useful.

Thanks

On Mar 26, 6:45 pm, James <james.gp....@gmail.com> wrote:
> Does this happen in both IE and Firefox, or only in IE?
>
> If it's only in IE, IE has some kind of issue with returning XML with
> the incorrect header content type.
> Check the bottom of this post for a 
> function:http://groups.google.com/group/jquery-en/browse_thread/thread/036d49a...
>
> Try using the function text2html by Diego A. on the returned XML data.
> Before you do that, remove the dataType:"xml" and contentType:"text/
> xml" from your AJAX call so that IE will not error on the response due
> to mismatched content type.
>
> On Mar 26, 7:01 am, moocher <shaunaus...@hotmail.co.uk> wrote:
>
>
>
> > Hi,
> > I'm very new to JQuery and am having a problem with an Ajax call that
> > returns xml. The error event is being fired, but the textStatus value
> > is 'parserror' and the errorThrown value is 'undefined'. The xml
> > response is valid so i'm not sure what could be wrong.
>
> > $.ajax({
> >     beforeSend: function() {
>
> >      },
> >     type: "GET",
> >     url: "ajaxttest.asp",
> >     dataType: "xml",
> >     timeout: 1000,
> >     contentType: "text/xml",
> >     success: function(xml) {
> >         alert("in");
>
> >     complete: function(XMLHttpRequest, textStatus) {
> >                 alert("comp");
> >     },
> >      error: function(XMLHttpRequest, textStatus, errorThrown) {
> >         alert(textStatus);
> >      }
>
> > });
>
> > Xml:
>
> > <addresses><address><number>6</number></address></addresses>
>
> > Any help would be great.- Hide quoted text -
>
> - Show quoted text -

Reply via email to