I want to show loading gif while I fetch my actual content from the server. I know how to get this done if it was just that. The problem I am facing is that I want to show this loading gif as a modal box. Can some one help ?
Edited: Here is what I am doing in my code
$('#'+buttonId).click(function(){
// Put an animated GIF image insight of content
$.fn.colorbox({html:"<img src='/mysite/images/" + imageId + "'/>", open:true, opacity:"0.60"});
// Make AJAX call
$('#'+ divId).load("/mysite/" + urlToLoad);
});
Here I am trying to using colorbox for the modal functionality and this does give me the modal window ... but the window remains open even after the content is loaded behind it.