While working on a dropdown control, I realised that the first time I change the selection in the dropdown, it was calling $(document).ready function.
This was happening because on changing the selection, I was opening a jquery dialog. This dialog had the following structure
Now open in the dialog was triggering the document.ready. I change removed that, and added autoOpen: true.
This fixed the problem!
},
This was happening because on changing the selection, I was opening a jquery dialog. This dialog had the following structure
$('#name).dialog({
title: 'abc',
height: 200,
width: 600,
modal: true,
open: function (event, ui) {
$(this).css('font-style', 'normal').html(alertmsg);
}
Now open in the dialog was triggering the document.ready. I change removed that, and added autoOpen: true.
This fixed the problem!
},