Hello,

I've been using flow with cforms for a while and the framework is great, but one thing that i found really uneasy is navigating in the dom tree with the dom api.

For exemple, i often do things like :
users = document.getDocumentElement().getElementsByTagName("users").item(0).getElementsByTagName("user");
and then i have to iterate all nodes to find the one i want :
for(var i=0; i < users.getLength(); i++){
   //Test each node against a property eg : id to find the node i want
  if(users.item(i).getAttribute('id').equals("foo")){
     //The node is finally found...
 }
}

Now i would like to know if there is a class somewhere in the cocoon distribution that allows to use the much more convenient xpath syntax to navigate in the dom.

Hopefully, sth like user = Utils.evalSax(document, "authentication/users/[EMAIL PROTECTED]'foo']");

Does something similar to this exist ?

Thanks,

Marc

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to