網頁分層

摘要:網頁分層

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=big5">
<title>最新消息</title>

<style type="text/css" >
#redblock {
  z-index: 1;
  position:
  absolute;
  width:80px;
  height:100px;
  top:20px;
  left:20px;
  border: 1px solid #FFF;
  background-color: #FF0000;
}

#pinkblock {
  z-index: 2;
  position: absolute;
  width:100px;
  height:80px;
  top:20px;
  left:30px;
  border: 1px solid #FFF;
  background-color: #FF00FF;
}

#pinkblock {
  z-index: 2;
  position: absolute;
  width:100px;
  height:80px;
  top:20px;
  left:30px;
  border: 1px solid #FFF;
  background-color: #FF00FF;
}


</style>
</head>

<body   >
<div id="redblock"><img id="pic" src="images/homepage_manu.jpg" ></div>
<div  id="pinkblock"><a href="http://tw.yahoo.com/" >55555</a></div>

</body>

</html>