jquery-ui对话框显示关闭图标和错误的文本 [英] jquery-ui dialog display close icon and wrong text

查看:104
本文介绍了jquery-ui对话框显示关闭图标和错误的文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

jquery-ui对话框显示关闭图标并关闭"错误的文本.

jquery-ui dialog display close icon and "close" wrong text..

jquery Ui版本1.12.1和代码:

jquery Ui version 1.12.1 and code:

function callDialog() {
    $("#dialog-confirm").dialog({
        closeOnEscape: false, resizable: false, height: "auto", width: 400, modal: true, buttons: {
            "Yes": function () {
                $(this).dialog("close"); },
            "No": function () {
                $(this).dialog("close"); }
         }
    });
}

如何修复

推荐答案

我已经解决了添加closeText的问题(请参见最后一行):

I've solved this adding closeText (see the last line):

		$('#dialog').dialog({
			autoOpen: false,
			width: 500,
			height:500,
			resizable: true,
			title: 'Items',
			modal: true,
			open: function(event, ui) {
				$(this).load("@Url.Action("StorageItemListPartial", "StorageItem")");
			},
			buttons: {
				"Close": function () {
					$(this).dialog("close");
				}
			},
			closeText: ''
		});

这篇关于jquery-ui对话框显示关闭图标和错误的文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆