jquery右下角弹出广告

  • A+
所属分类:Web前端
<!DOCTYPE html> <html>     <head>         <meta charset="utf-8" />         <meta name="viewport" content="width=device-width, initial-scale=1">         <title></title>          <script src="jquery-3.5.1.min.js" type="text/javascript" charset="utf-8"></script>          <script type="text/javascript">             // 入口函数             $(document).ready(function() {                 var jqSpan = $("span");                 var jqAd = $(".ad");                  jqAd.slideDown("slow");                  jqSpan.click(function() {                     jqAd.fadeOut(1000);                 })             });         </script>          <style type="text/css">             .ad {                 position: fixed;                 right: 0;                 bottom: 0;                 width: 230px;                 height: 220px;                 background-color: red;                 /* display: none; */             }              .ad span {                 position: absolute;                 right: 0;                 top: 0;                 width: 40px;                 height: 18px;                 background-image: url(close.jpg);                 cursor: pointer;             }         </style>     </head>     <body>         <div class="ad">             <span></span>         </div>     </body> </html>

jquery右下角弹出广告