Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>JS Bin</title>
  <link rel="stylesheet" href="http://cdn.amazeui.org/amazeui/2.2.1/css/amazeui.min.css">
</head>
<body>
  <button class="am-btn am-btn-primary" id="demo-btn">Modal</button>
<div class="am-modal am-modal-no-btn" tabindex="-1" id="demo-modal">
  <div class="am-modal-dialog">
    <div class="am-modal-hd">Modal 标题
      <a href="javascript: void(0)" class="am-close am-close-spin" data-am-modal-close>&times;</a>
    </div>
    <div class="am-modal-bd">
      Modal 内容。本 Modal 无法通过遮罩层关闭。
    </div>
  </div>
</div>
<script src="//code.jquery.com/jquery-2.1.1.min.js"></script>
<script src="http://cdn.amazeui.org/amazeui/2.2.1/js/amazeui.min.js"></script>
<script>
  (function($) {
    $(function() {
      var $modal = $('#demo-modal');
      
      $('#demo-btn').on('click', function() {
        $modal.modal({closeViaDimmer: 0, width: 400, height: 225});
      });      
      
    });
  })(jQuery);
</script>
</body>
</html>
Output 300px

This bin was created anonymously and its free preview time has expired (learn why). — Get a free unrestricted account

Dismiss x
public
Bin info
anonymouspro
0viewers