只是一個普遍的問題。根據API的jQuery對話框,Dosen'允許將主題包含在它的參數中。所以我猜測每個主題都必須像這樣宣佈。是否有可能擁有2個Dialog主題
<link href="//ajax.googleapis.com/ajax/libs/jqueryui/1.8.14/themes/smoothness/jquery-ui.css" rel="stylesheet" type="text/css" />
<link href="//ajax.googleapis.com/ajax/libs/jqueryui/1.8.14/themes/cupertino/jquery-ui.css" rel="stylesheet" type="text/css" />
如何在模式對話框中使用第二個主題,因爲我無法看到從對話框中調用主題的方法。我在下面列出了示例代碼。所以我的問題是,如何在代碼中調用特定的主題。謝謝
$("#box_frtv").bind("chosen:maxselected",
function() {
//alert('Only 1 box can be selected. Thank you.');
$("html").append("<div id='dialog-bferror' />");
var $dialogBFError = $("#dialog-bferror");
$dialogBFError.html('<br />Only 1 box can be selected . Thank you.');
$dialogBFError.dialog({
autoOpen: true,
modal: true,
title: 'File Error',
position: ['center', 'center'],
width: 400,
height: 200,
draggable: true,
resizable: false,
buttons: {
Close: function() {
$(this).dialog("close");
}
}
});
});
只需編輯第二個CSS爲了使用樣式和類的對話框或重命名類。 – Hackerman 2014-09-04 19:04:11
羅伯特你可以擴大你的答案請。謝謝 – user1532468 2014-09-04 19:11:27