The following java-script is working fine (Jquery)
$(document).ready(function(){
$('#c_area').load($('.m_top:first').attr('href'))
});
$('.m_top').click( function(){
$("#myDiv").html('<img src="images/loading.gif" alt="Wait" />');
var name= $(this).attr('href');
$('#c_area').hide().load(name).fadeIn('normal');
$("#myDiv").html('');
return false;
});
I want to show the loading image (spinner) for 2 seconds minimum, because when page has already loaded, while click again on link, loading image (spinner) not display again because the page already loaded.
minimum time = 2 second
maximum time = until the contents loaded