0
웹 페이지를로드 할 때 자동으로 열리는 대화 상자가 있습니다. 나는 그것을 원하지 않는다.웹 페이지를로드 할 때 대화 상자가 자동으로 표시됩니다.
가 나는 이미지를 넣어 내가 그것을 클릭하면, 나는 열려있는 대화
내 JS
$("#deleteReportButton").click(function() {
$("#deleteReportConfirm").dialog("open");
});
$("#deleteReportConfirm").dialog({
resizable: false,
height: 140,
modal: true,
buttons: {
"Delete report": function() {
$(this).dialog("close");
},
Cancel: function() {
$(this).dialog("close");
}
}
});
HTML 부분을 원하는 당신은에 AutoOpen 옵션을 추가 할 필요가
<div id="deleteReportConfirm" title="Delete report?" style="display:none">
<p>....</p>
</div>
<img id="deleteReportButton" src="/plato/resources/images/delete.png" />
이상하게, 그것은 제가 추가 내 jsfiddle을 확인하기위한 –
잘 작동 immidiately 마감했다. 그것의 아직도 닫히는 경우에 당신은 열리는 그것에 그것을 닫고있는 다른 어떤 사건이있다. – Chausser