Question

I am looking for a good online reference to working with XML in Javascript. Specifically, I am using the protoype library. I have my ajax response with a valid responseXML document.

I can find all sorts of online examples for looking at the data in the first child node of the first element tagged 'X', but that doesn't help me. What I need to know how to do is to find all elements tagged 'X' and then look at the values of several different child nodes of each of these elements, and then based on that information, manipulate them with javascript.

So, I need a more in depth resource of examples using Javascript and XML, ideally within the context of prototype.

Any suggestions?

Was it helpful?

Solution

It sounds like you need to learn about XPath. Here is a nice XPath Tutorial.

OTHER TIPS

This is a very broad question - it sounds like you need to read a book or two.

I would search a bookstore for "prototype javascript" or "prototype javascript ajax".

This book may be a good one, assuming that Barnes and Noble's link does not break:

Prototype and Scriptaculous in Action

One of the authors is the same author of jQuery in Action which I found to be a spectacular book.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top