Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > JavaScript > Siple AJAX, of ...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 3 Topic 35544 of 36378
Post > Topic >>

Siple AJAX, of course

by Monica Leko <monica.leko@[EMAIL PROTECTED] > May 9, 2008 at 10:48 AM

Doesn't work.  :)

I am using Google maps example from book, and from Google
do***entation.  It is really simple, and I don't know why isn't
working.  My browser send mi this response:

This XML file does not appear to have any style information associated
with it. The do***ent tree is shown below.
<markers id="id je ok">
<marker found="Keychain" lat="37.441" left="Book" lng="-122.141"/>
<marker found="Water Bottle" lat="37.322" left="Necklace"
lng="-121.213"/>
</markers>

My code is following
var getVars =  "?q=" + search;
var request = GXmlHttp.create();
request.open('GET', '/lbs/' + getVars, true);
request.onreadystatechange = function() {
  if (request.readyState == 4) {
    var xmlDoc = request.respon***ML;
    alert(xmlDoc);
    var responseNode = xmlDoc.getElementsByTagName('markers').item(0);
    var type = responseNode.getAttribute("id");
  }
}

respon***ML allways sends back null value, although server sends back
XML.  And, what I don't understanf (still newbie), after the alert
popups and write "null", my browser render upper XML file, instead
doing nothing and show page from which I called AJAX function.  How
can this be?
 




 3 Posts in Topic:
Siple AJAX, of course
Monica Leko <monica.le  2008-05-09 10:48:34 
Re: Siple AJAX, of course
Tom Cole <tcole6@[EMAI  2008-05-09 11:57:52 
Re: Siple AJAX, of course
Monica Leko <monica.le  2008-05-09 12:34:22 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Fri Jul 25 17:51:37 CDT 2008.