分享好友 教程首页 教程搜索 频道列表

CSS3右侧悬停显示二维码返回顶部代码

2016-02-10 12:4511460
+关注28
核心提示:网页代码:

网页代码:

<html xmlns="https://www.w3.org/1999/xhtml"><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>CSS3悬停显示二维码返回顶部代码 - 站长素材</title>

<link type="text/css" rel="stylesheet" href="https://3721wang.com/view/jiaoben3565/css/style.css">

</head>
<body style="height:2000px;">
<div class="toolbar">
   <a href="###" class="toolbar-item toolbar-item-weixin">
   <span class="toolbar-layer"></span>
   </a>
   <a href="###" class="toolbar-item toolbar-item-feedback"></a>
   <a href="###" class="toolbar-item toolbar-item-app">
    <span class="toolbar-layer"></span>
   </a>
   <a href="javascript:scroll(0,0)" id="top" class="toolbar-item toolbar-item-top"></a>
</div>

<div style="text-align:center;margin:50px 0; font:normal 14px/24px 'MicroSoft YaHei';">
<h1>向下滚动!!!</h1><br>
<p>适用浏览器:360、FireFox、Chrome、Safari、Opera、傲游、搜狗、世界之窗. 不支持IE8及以下浏览器。</p>
</div>

</body></html>

CSS如下:


@charset "utf-8";

.toolbar-item,.toolbar-layer{background:url(../images/toolbar.png) no-repeat;}
.toolbar{position:fixed;right:0px;bottom:50px;}
.toolbar-item{display:block;width:52px;height:52px;margin-top:1px;position:relative;-moz-transition:background-position 1s;-ms-transition:background-position 1s;-o-moz-transition:background-position 1s;-webkit-moz-transition:background-position 1s;transition:background-position 1s;}
.toolbar-item:hover .toolbar-layer{opacity:1;filter:alpha(opacity=100);transform:scale(1);-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);}
.toolbar-item-weixin{background-position:0 -798px;}
.toolbar-item-weixin:hover{background-position:0 -860px;}
.toolbar-item-weixin .toolbar-layer{height:212px;background-position:0 0;}
.toolbar-item-feedback{background-position:0 -426px;}
.toolbar-item-feedback:hover{background-position:0 -488px;}
.toolbar-item-app{background-position:0 -550px;}
.toolbar-item-app:hover{background-position:0 -612px;}
.toolbar-item-app .toolbar-layer{height:194px;background-position:0 -222px;}
.toolbar-item-top{background-position:0 -674px;}
.toolbar-item-top:hover{background-position:0 -736px;}
.toolbar-layer{position:absolute;right:46px;bottom:-10px;width:172px;opacity:0;filter:alpha(opacity=0);
transform-origin: 95% 95%;-moz-transform-origin: 95% 95%;-ms-transform-origin: 95% 95%;-o-transform-origin: 95% 95%;-webkit-transform-origin: 95% 95%;transform:scale(0.01);
-moz-transform:scale(0.01);-ms-transform:scale(0.01);-o-transform:scale(0.01);-webkit-transform:scale(0.01);transition:all 1s;-moz-transition:all 1s;-ms-transition:all 1s;-o-transition:all 1s;-webkit-transition:all 1s;}

素材:
 


效果图:


CSS3右侧悬停显示二维码返回顶部代码


整理员:小黑
免责声明:凡注明来源本网的所有作品,均为本网合法拥有版权或有权使用的作品,欢迎转载,注明出处。非本网作品均来自互联网,转载目的在于传递更多信息,并不代表本网赞同其观点和对其真实性负责。
生成海报
最新其他更多

js 生成四个随机字母或数字+js获取当前日期

    js获取当前的日期和时间

网络转载 JS相关 22021-12-25

js实现字符串隔4位或隔2位 添加符号(空格、- 等)

    1、每隔4位添加 - ,2、每隔2位添加

网络转载 JS相关2021-12-24

让网页标签页头部有新消息提醒和Title标题文字滚动显示效果

    demo展示HTML!DOCTYPEhtmlPUBLIC-//W3C//DTDXHTML1.0Transitional//ENhttp://www.w3.org/TR/xhtml1/DTD/xht

小黑 HTML相关2021-12-24

前端开发技术之JS实现类似手风琴左右拉动效果

    JS实现类似手风琴效果效果如下

网络转载 HTML相关 12021-12-23

下一篇
我来说两句
抢沙发