I see, thanks guys. I guess I can't do it without making server side changes.
O well! Dan On 5/23/07, Mike Alsup <[EMAIL PROTECTED]> wrote: > > > The key to this working properly is to ensure that the server is > returning its response with an XML mime type. > > In PHP do this: > <?php header('Content-type: text/xml'); ?> > > In JSP do this: > <[EMAIL PROTECTED] contentType="text/xml"%> > > In CF do this: > <cfheader name="Content-Type" value="text/xml"> > > Mike > > On 5/22/07, Danbh <[EMAIL PROTECTED]> wrote: > > > > Hey everyone, > > I'm trying to use the jQuery.ajax function, to fetch a webpage on > > which I would like to run some jQuery on that page. > > > > The problem that I am running into is that dataType field. I am > > setting it to xml, but ajax keeps returning text. Here is the code: > > > > XML_page = jQuery.ajax({ //get the whole page via ajax > > url: "", > > data: 'q='+mucie_get_q(), > > async: false, > > dataType: "xml", > > }); > > > > XML_page.responseXML will be equal to null, but .responseText will > > contain the document. > > > > > > I've also tried converting responseText to something useful, using > > jQuery(responseText), but that hasn't worked for me either. When I > > try to find/select by id, i get "this.getElementsByTagName is not a > > function" > > > > Any advice for the problems that I am running into, either getting > > ajax to return a DOM, or converting the string to a DOM? > > > > Thanks, > > Dan > > > > > -- There are those who see the events and emotions of life as defining who they are, and there are those who see the events and emotions of life as the inspiration for what is to be.