html - 如何在网站中添加加载效果?

标签 html css

我正在做一个网站,但我不知道页面加载效果。 我尝试使用网站 [ http://www.realcombiz.com/2013/12/35-amazing-loading-animation-effects.html] 中显示的效果但它只是在网站上显示动画,而不是在页面加载时显示。

最佳答案

Check this out ,it shows the first loading effect in your link given

HTML

<div id="overlay">
    <!--  <img src="http://cdn.nirmaltv.com/images/generatorphp-thumb.gif" alt="Wait" alt="Loading" />-->
    <div class="circ">
  <div class="load">Loading...</div>
  <div class="hands"></div>
  <div class="body"></div>
  <div class="head">
    <div class="eye"></div>
  </div>
</div>
<div id="overlayText">


        </div>
    </div>
    <div id="container"  >

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
    </div>

查询

    //  1.0);This sets the opacity to 100% on hover },function(){ 


var delay = 3000;
setTimeout(function() 

    {  

        $( "#overlay" ).fadeOut( "slow" );

         $('#container').fadeIn();

    },
    delay
) ;

CSS

#overlayText{
     position:absolute;
    top:365px;
    left: 330px;

   z-index:11;

}

#container{
    position:relative;
       display:none;
}
#overlay{

  width:100%;
    height:100%;
    position: absolute;
    top:0px;
    z-index: 2;
    background-color:#222;
    opacity:0.7;



}

@import url(http://fonts.googleapis.com/css?family=Julius+Sans+One);
html{width: 100%;height: 100%;}


.eye{
  width: 20px; height: 8px;
  background-color: #eee;
  border-radius:0px 0px 20px 20px;
  position: relative;
  top: 40px;
  left: 10px;
  box-shadow:  40px 0px 0px 0px #eee;              
}

.head{
  -webkit-backface-visibility: hidden;
  position: relative;
  margin: -250px auto;
  width: 80px; height: 80px;
  background-color: #111;
  border-radius:50px;
  box-shadow: inset -4px 2px 0px 0px #eee;
    -webkit-animation:node 1.5s infinite alternate;
  -webkit-animation-timing-function:ease-out;
}
.body{ 
  position: relative;
  margin: 90px auto;
  width: 140px; height: 120px;
  background-color: #111;
  border-radius: 50px/25px ;
  box-shadow: inset -5px 2px 0px 0px #eee;
  -webkit-animation:node2 1.5s infinite alternate;
  -webkit-animation-timing-function:ease-out;  
}

  @-webkit-keyframes node 
      {
         0%{ top:0px; }
         50%{ top:10px; }
         100% { top:0px;} 
       }

  @-webkit-keyframes node2
      {
         0%{ top:-5px; }
         50%{ top:10px; }
         100% { top:-5px;} 
       }

.circ{
  -webkit-backface-visibility: hidden;
   margin: 60px auto;
  width: 180px; height: 180px;
  background-color: #111;
  border-radius: 0px 0px 50px 50px;
  position: relative;
  z-index: -1;  
  left: 0%;
  top: 20%;
  overflow: hidden;
}

.hands{
  -webkit-backface-visibility: hidden;
  margin-top: 140px;
  width: 120px;height: 120px;
  position: absolute;
  background-color: #111;
  border-radius:20px;
  box-shadow:-1px -4px 0px 0px #eee;
  -webkit-transform:rotate(45deg);
  top:75%;left: 16%;
  z-index: 1;
  -webkit-animation:node2 1.5s infinite alternate;
  -webkit-animation-timing-function:ease-out;
}

.load{  position: absolute;
  width: 100px; height: 20px;
   margin: -10px auto;
  -webkit-font-smoothing: antialiased;
  font-family: 'Julius Sans One', sans-serif;
  font-size:30px;
  font-weight:400;
  color:#eee;
  left: 10%;
  top: 5%;
}

关于html - 如何在网站中添加加载效果?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31846766/

相关文章:

html - 如何使用CSS制作跑马灯样式

html - Colgroup 和 Col 在桌面上不可见

java - 在线运行.JSP文件

JavaScript 关闭帮助

javascript - 在拖动操作未完成之前,浏览器不遵守新的 css 设置

html - 将 gzip 压缩的 css 文件导入 html 标题?

javascript - 如何在两个列表框之间移动元素?

html - "Share this link"HTML 小部件

javascript - 有没有办法从 html 内容中提取有效的脚本并使用 jQuery 执行它?

javascript - 如何正确捕捉 mouseout 事件?