yeah, thats basically what i was thinking. personally i'd try to track the container and use a generic piece of code for the the loading image. that way you could just use $ (container).child(".loading") to traverse the DOM.
or if for any reason you want to make them unique perhaps even build an id for each loading image based on the container's id. (eg. cont1 > cont1_Img or something)