Hi
Event.observe(window,"load",function() {
$$(".elem_classs").findAll(function(node){
return node.getAttribute('title');
}).each(function(node){
new Tooltip(node,node.title);
node.removeAttribute("title");
});
});
Using above method, I can retrieve all elements having ".elem_class"
and apply some javascript functions on them. But I have a modal/popup box which has some elements also having ".elem_class" and these dont get in the scope of findAll/each as they are loaded into the dom thru ajax.
How do I apply the same to dynamically loaded elements as well? I am using Prototype Library. (I have used JQuery's Live function which keeps track of all future elements, but need to achieve something similar using Prototype)
Thanks.