Show modal dialog with 'x' without using jqueryui

前端 未结 2 1818
不知归路
不知归路 2020-12-22 09:53

looking for a very simple implementation of modal dialog box without using jquery UI.

just for example

2条回答
  •  醉梦人生
    2020-12-22 10:43

    I think you're looking for something like this:

    $('.modal .titlebar a').click(function() {
      $(this).parents('.modal').hide();
    });
    
    $('button.open-modal').click(function() {
      $('#something').show();
    });
    

提交回复
热议问题