greenkarmic

How to modify InfoTemplate content dynamically when it's displayed

Discussion created by greenkarmic on May 8, 2012
Latest reply on May 8, 2012 by greenkarmic
Hi,

I have several feature layers in my map, and each of them have graphics that when clicked display a different InfoTemplate.
I saw that whenever a popup is displayed, the <div class="esriPopup"> element's content is updated with the correct infoTemplate content (depending on the graphic clicked).
Now, I'd like to be able to dynamically edit this content when the popup is displayed, for instance maybe do things like that:

$(".esriPopup").find(".popup-button").on("vmousedown", function(){ // do things });       // popup button onclick

but to do this I need to know when the DOM has finished updating


TLDR: Is there any ArcGIS for Javascript API event I could bind to so that I could execute some of my code when a popup is displayed?

Thanks

Outcomes