如何将文档就绪代码移至对话框回调中?
var rateDialog;$('<div id="ratingloaderDiv"></div>') .load("ratingDialog.jsp", function() { rateDialog = $(this).dialog({ autoOpen: true, minHeight:275, width: 400, height: 350, open: function( event, ui ) { $("#showDialogMessage").hide(); $('#reviewArea').val(''); $('#source').attr('checked', false); $('#destination').attr('checked', false); // document ready $(".rateStar").show(); $(".rateCls").rating(); alert('hi'); } }); });将对话框调用移至您的加载回调也可以确保它在检索到文件之前不会运行。



