The problem I'm having is it is creating some anchors I need to access in JavaScript without a name or ID attribute. There is also no way in the XML i can assign these objects a name or ID.
That may not be true. If you can access or modify the XSL that is doing the XML to HTML translation then you can make it do anything you want..... well most things.
For example, I have this <dateField> xml tag I create. This renders on the HTML page as a input field and a calendar image with an anchor that has an onlick attribute that spawns a pop-up date picker. I need to access the anchor for that date picker, but UIX does not render the anchor tag with an ID or with a name.
What is it you need to access the A tag for? i.e. What change do you need to make? Replacing the A tag with a SPAN tag, and setting the onclick, onmouseover, etc events might give you what you need.
You can access the A tab manually thought the HTML tag hierarchy, but it is really annoying to do and is easily broken by changes in the HTML. To do this you would need to do something like document.body.<<some tag>>.<<some tag>>.<<some tag>>.<<A tag>>. Or if the A tag is a child of a tag you can identify you could do something like document.getElementById('<<Id of known parent tag>>').childNodes(); and then loop though the array returned to try and find the tag you need.
Is there some way to get an array of ALL objects in the document, even if they DO NOT have an ID?
Well you could do something like document.body.getElementsByTagName('A'); I am not sure if that would be recursive and read the entire page, or just read one level.
The other option would be document.body.childNodes which would return an array of the tags under the body tag, and then you would need to recursively read though each node of that array for their child nodes over and over until you read though all of the tags on the page.