首页 技术 正文
技术 2022年11月10日
0 收藏 428 点赞 2,767 浏览 2074 个字
 <!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
  <style> 
      * { padding: 0; margin: 0; }body { background: #42509a; }      ul { width: 800px; height: 500px; border: 1px solid #333; background: #05090e; overflow: hidden; position: relative; margin: 50px auto 0; }

      li { position: absolute; list-style: none; }
      #pic1 { top: 210px; left: 550px; }
      #pic2 { top: 290px; left: 430px; }
      #pic3 { top: 215px; left: 220px; }
      #pic4 { top: 150px; left: 100px; }
      #pic6 { top: 290px; left: 80px; }
      #pic7 { top: 120px; left: 480px; }
      #pic8 { top: 60px; left: 380px; }
      #pic5 { top: -40px; left: -50px; width: 1422px; height: 1000px; background: url(../images/bg.jpg) no-repeat; }

      p{text-align:center; padding:10px 0; color:#FFF;}
      p a{color:#FFF; text-decoration:none;}
      p a:hover{text-decoration:underline;}

   </style>
<script>
window.onload=function(){
var oUl=document.getElementById('ul_container');
var aLi=oUl.getElementsByTagName('li');
var x=;
var y=;
document.onmousedown=function(ev){
var oEvent=ev || event;
var disX=oEvent.clientX-x;
var disY=oEvent.clientY-y;
document.onmousemove=function(ev){
var oEvent=ev||event;
x= oEvent.clientX-disX;
y=oEvent.clientY-disY;
for(var i=;i<aLi.length;i++){
aLi[i].style.marginLeft=x*aLi[i].style.zIndex/+'px';
aLi[i].style.marginTop=y*aLi[i].style.zIndex/+'px';
}
};
document.onmouseup=function(){
document.onmousemove=null;
document.onmouseup=null;
document.reseaseCapture&&document.reseaseCapture();
};
document.setCapture&&document.setCapture();
return false;
};
};
</script>
</head> <body> <ul id="ul_container">
<li id="pic1" style="z-index: 3;"><img src="data:images/1.jpg" alt="" /></li>
<li id="pic2" style="z-index: 4;"><img src="data:images/2.jpg" alt="" /></li>
<li id="pic3" style="z-index: 5;"><img src="data:images/3.jpg" alt="" /></li>
<li id="pic4" style="z-index: 4;"><img src="data:images/4.jpg" alt="" /></li>
<li id="pic6" style="z-index: 3;"><img src="data:images/5.jpg" alt="" /></li>
<li id="pic7" style="z-index: 2;"><img src="data:images/6.jpg" alt="" /></li>
<li id="pic8" style="z-index: 5;"><img src="data:images/7.jpg" alt="" /></li>
<li id="pic5" style="z-index: 1;"></li>
</ul> </body>
</html>
相关推荐
python开发_常用的python模块及安装方法
adodb:我们领导推荐的数据库连接组件bsddb3:BerkeleyDB的连接组件Cheetah-1.0:我比较喜欢这个版本的cheeta…
日期:2022-11-24 点赞:878 阅读:9,111
Educational Codeforces Round 11 C. Hard Process 二分
C. Hard Process题目连接:http://www.codeforces.com/contest/660/problem/CDes…
日期:2022-11-24 点赞:807 阅读:5,584
下载Ubuntn 17.04 内核源代码
zengkefu@server1:/usr/src$ uname -aLinux server1 4.10.0-19-generic #21…
日期:2022-11-24 点赞:569 阅读:6,431
可用Active Desktop Calendar V7.86 注册码序列号
可用Active Desktop Calendar V7.86 注册码序列号Name: www.greendown.cn Code: &nb…
日期:2022-11-24 点赞:733 阅读:6,203
Android调用系统相机、自定义相机、处理大图片
Android调用系统相机和自定义相机实例本博文主要是介绍了android上使用相机进行拍照并显示的两种方式,并且由于涉及到要把拍到的照片显…
日期:2022-11-24 点赞:512 阅读:7,838
Struts的使用
一、Struts2的获取  Struts的官方网站为:http://struts.apache.org/  下载完Struts2的jar包,…
日期:2022-11-24 点赞:671 阅读:4,922