所以我有我的UI按鈕調用此JavaScript函數:JQuery的對話框幫助
function OpenHistory(transactionId, spanThatWasClicked)
{
$.ajax({
type: "POST",
url: "<%= Url.Action("ViewHistory", "Indications") %>",
data : { transactionId : transactionId },
success: function(data) {
$("#history").html(data);
$("#history").dialog({
modal: true,
resizable: false,
title: "Valuation History",
width: 850,
height: 500,
autoOpen: true,
buttons: { "Close": function() { $(this).dialog("close"); } }
});
}
});
}
的#history
它的設置只是看起來像這樣在頁面上:<div id="history"></div>
我第一次點擊 - - 進行AJAX調用,打開對話框,一切都看起來很完美。
關閉對話框
我第二次單擊它 - 沒有任何反應。它使得AJAX調用和所有事情都成爲可能,但屏幕上沒有出現對話框。
刷新頁面
它可以追溯到上第一隻點擊,同上次一樣再次合作。
這是一些對話怪異?
謝謝。
尼爾打開你的天才:) – slandau 2011-05-04 18:42:20
@slandau,還得感謝還得感謝還得感謝很^ _ ^ – Neal 2011-05-04 18:43:48