• 弹框组件


    <!DOCTYPE html>
    <html>
        <head>
            <meta charset="UTF-8">
            <title></title>
            <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
            <!--bootstrap要引入的文件:bootstrap.min.css,jquery.min.js,bootrap.min.js-->
            <link rel="stylesheet" type="text/css" href="css/bootstrap.css"/>
            <script src="js/jquery-1.11.0.js" type="text/javascript" charset="utf-8"></script>
            <!--要在bootstrap之前引入jquery,bootstrap依赖JQUERY,因为bootstrapJS里要使用$这个jquery变量-->
            <!--<script src="js/popper.js" type="text/javascript" charset="utf-8"></script>-->
            <!--如果你要用bootstrap使用一些提示性的交互,那么就需要引入提示性的框架popper.js,因为bootstrap的提示就是依赖popper-->
            <script src="js/bootstrap.js" type="text/javascript" charset="utf-8"></script>
        </head>
        <body>
            
            <div class="container">
                <div class="row">
                    <div class="alert alert-danger col-6 offset-3">
                        这是1个弹框<a class="alert-link" href="http://www.baidu.com">百度</a>
                        <button type="button" class="close" data-dismiss="alert">
                            <span>&times;</span>
                        </button>
                    </div>
                </div>
            </div>
            
            <div class="alert alert-primary" role="alert">
      This is a primary alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-secondary" role="alert">
      This is a secondary alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-success" role="alert">
      This is a success alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-danger" role="alert">
      This is a danger alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-warning" role="alert">
      This is a warning alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-info" role="alert">
      This is a info alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-light" role="alert">
      This is a light alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
    <div class="alert alert-dark" role="alert">
      This is a dark alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
    </div>
            
            
            
            <script type="text/javascript">
                $('.alert').on('close.bs.alert',function(e){
                    console.log('弹框关闭之前执行什么内容')
                    console.log(e)
                }).on('closed.bs.alert',function(e){
                    console.log('弹框关闭之后执行什么内容')
                    console.log(e)
                })
            </script>
        </body>
    </html>
  • 相关阅读:
    多线程 信号量
    sql在不同数据库查询前几条数据
    Office Outlook同步 很奇怪的BUG
    搜索小技巧整理
    想做一个权限管理插件
    ibatis和Castle学习历程
    查找存储过程中的错误位置
    VS2005项目模版丢失解决方案及VS2005项目模版查找原理
    C# 邮件发送接收
    数据库优化整合
  • 原文地址:https://www.cnblogs.com/wwthuanyu/p/10554975.html
Copyright © 2020-2023  润新知