Home  >  Article  >  Web Front-end  >  If display is not set in css, the animation effect cannot be displayed! _html/css_WEB-ITnose

If display is not set in css, the animation effect cannot be displayed! _html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:49:141379browse

 1  <script type="text/javascript" src="jquery-1.7.1.js"></script> 2     <script type="text/javascript"> 3  4         $(document).ready(function(){ 5  6             var x = 10; 7             var y = 10; 8  9             $('.prompt_a').mouseover(function(e){10 11                 var prompt_div = "<div class='prompt_div_cls'>"+this.title+"</div>";12 13                 $('body').append(prompt_div);14 15                 $('.prompt_div_cls').css({"left":(e.pageX+x)+"px","top":(e.pageY+y)+"px"})16                         .show("fast");17 18             }).mouseout(function(){19 20                 $('.prompt_div_cls').remove();21 22             }).mousemove(function(e){23                         $('.prompt_div_cls').css({"left":(e.pageX+x)+"px","top":(e.pageY+y)+"px"});24 25             })26         });27 28     </script>29     <style type="text/css">30 31         .prompt_div_cls {width: 300px;height: 200px;border: 1px solid #ccc;background-color: #eee;position: absolute;display: none;}32 33     </style>34 </head>35 <body>36     <a class="prompt_a" href="#" title="提示信息提示信息提示信息提示信息提示信息提示信息提示信息37     提示信息提示信息提示信息提示信息提示信息提示信息提示信息38     提示信息提示信息提示信息提示信息提示信息提示信息提示信息39     提示信息提示信息提示信息提示信息提示信息提示信息提示信息40     提示信息提示信息提示信息提示信息提示信息提示信息提示信息41     提示信息提示信息提示信息提示信息提示信息提示信息提示信息">弹出提示信息</a>42 </body>43 </html>


If you don’t believe it, you can try removing the display! ! ! Anyway, I believe it! ! !

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn