hello,
i have this script which works fine, it works on all click like submit, linkbutton and SPAN click also
i want it checks if click is SPAN so it should not call showprogress function else it should call showprogress function
so if click is span i do not want to call funciton
<script type="text/javascript">
function ShowProgress() {
setTimeout(function () {
var modal = $('<div />');
modal.addClass("modal");
$('body').append(modal);
var loading = $(".loading");
loading.show();
var top = Math.max($(window).height() / 2 - loading[0].offsetHeight / 2, 0);
var left = Math.max($(window).width() / 2 - loading[0].offsetWidth / 2, 0);
loading.css({ top: top, left: left });
}, 200);
}
$('form').live("click", function () {
ShowProgress();
});
</script>
actual issue with the code if you see code there is a tag which fires on form.click event due this tag when ever user click any where on page which is inside the form tag it starts showing loading bar.
i want that it should call function SHOWPGRESS() when user click on any control like linkbutton button or any click but it should be control click not form click