• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

Looping XMLHttpRequest

 
Ranch Hand
Posts: 838
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to have a looping XMLHttpRequest put in place. First time in the normal XMLHttpRequest is used and a perl script is called for looking up values. The script passes values back in increments of 20 (20 users = first names, last names, etc..,). I keep track of the next number of process and try and recall the XMLHttpRequest object but something is going wrong somewhere. I have an alert of the responseText and there is a tag in there that I'm trying to check (using getElementsByTagName). The first time through I see my tag (<NextPos>0</NextPos>), the second time I see it (<NextPos>21</NextPos>). I then iterate through the values in the lookup table. Anyone happen to know what could possibly be the problem? Below is the code. The line "dObj.getElementsByTagName("NextItm").length" is where it's giving me a count of 0 but a couple of lines before that (alert) it shows me that the XML does have the tag <NextItm> in it. Any help would be greatly appreciated.

 
Fire me boy! Cool, soothing, shameless self promotion:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic