-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcss3名片特效.html
58 lines (52 loc) · 1.91 KB
/
css3名片特效.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>css3名片特效 | 镜心书社</title>
<link rel="stylesheet" type="text/css" href="style/pic-scroll-out.css">
</head>
<body>
<img src="images/me.jpg" alt="" class="pic">
<div class="line"></div>
<div class="text">A CSS3 Demo. Do you like it?</div>
<div class="contact">
<p>E-mail: [email protected]</p>
<p>Blog: http://jxdxsw.com</p>
<p>微信公众号:镜心的小树屋</p>
</div>
<!--[if lt IE 9]>
<script type="text/javascript">
//<![[
var box = document.createElement("div"),
bug = {
position:'absolute',
'z-index': 9999,
top:'-51px',
height:'50px',
width:'100%',
'border-bottom':'1px solid #238432',
background:'orange',
'text-align': 'center',
'line-height': '50px',
'font-weight': 'bold'
}, key, csses = '', timer = null;
for(key in bug){
csses += key + ":" + bug[key] + ";";
}
box.style.cssText = csses;
box.setAttribute('id', 'bug');
box.innerHTML = "这个Demo只为Chrome准备,屌丝浏览器看不到效果~";
document.getElementsByTagName('body')[0].appendChild(box);
function ani(){
timer = setTimeout(ani, 10);
var top = parseInt(box.style.top);
if(top >= -1) clearTimeout(timer);
box.style.top = top + 1 + 'px';
}
setTimeout(ani, 800);
//]]>
</script>
<![end if]-->
<a href="https://github.com/AlexZ33/HTML5_CSS3/tree/master/CSS3_demo"><img style="position: absolute; top: 0; right: 0; border: 0;" src="images/forkme.png" alt="Fork me on GitHub"></a>
</body>
</html>