グローバリゼーションの目的で、jquery ダイアログのボタンを翻訳する必要がありますが、変数を渡そうとすると、変数の値が取得されず、変数の名前だけが取得されます。
var RemoveDialogButton = "@FriendsNamesNS.FriendsNames.Remove";
var CancelDialogButton = "@FriendsNamesNS.FriendsNames.Cancel";
//alert(RemoveDialogButton);
$( "#dialog-confirm" ).dialog({
autoOpen: false,
resizable: false,
height:190,
modal: true,
buttons: {
RemoveDialogButton: function() {
$( this ).dialog( "close" );
$('#yesno').click();
return true;
},
CancelDialogButton: function() {
$( this ).dialog( "close" );
}
}
});