jQueryUI modal dialog does not show close button (x)

后端 未结 15 2926
鱼传尺愫
鱼传尺愫 2020-12-12 23:45

I\'m using a jQuery modal dialog in my ASP .NET MVC 3 application. It works fine except for that there is no close button showing in the top right corner. How can I add thi

15条回答
  •  猫巷女王i
    2020-12-13 00:06

    Pure CSS Workaround:

    I was using both bootstrap and jQuery UI and changing the order of adding the scripts broke some other objects. I ended up using pure CSS workaround:

    .ui-dialog-titlebar-close {
      background: url("http://code.jquery.com/ui/1.10.3/themes/smoothness/images/ui-icons_888888_256x240.png") repeat scroll -93px -128px rgba(0, 0, 0, 0);
      border: medium none;
    }
    .ui-dialog-titlebar-close:hover {
      background: url("http://code.jquery.com/ui/1.10.3/themes/smoothness/images/ui-icons_222222_256x240.png") repeat scroll -93px -128px rgba(0, 0, 0, 0);
    }
    

提交回复
热议问题