1、CSS部分修改:
.hot_play{ position:relative}.hot_play ul{ float:left}
.hot_play li{ float:left position:relative width:95px margin:4px 19px 16px 0overflow:hidden}
.hot_play a img{ width:86px height:120px padding:2px border:1px solid #cfcfcf}
.hot_play a:hover img{ border-color:#8ECFF9}
2、定义好图片的坐标也可以:
<img src="static/images/ghot.gif" style="position:absolutez-index:1001margin-left:380pxmargin-top:1px">.hot_play span{display:block width:35px height:34pxposition:absolute left:0px top:0px}
.hot_play span.back{ background:url(images/hot.gif) no-repeat }
3、主页部分修改梁让:
<div class="hot_play"><ul>
<li>
<a href="/"><img src="/" alt="/"键灶></a>
<span class="back"><橡亮局/span>
</li>
</ul>
</div>
你好。给御扰你个简单的例子吧:<div style="width:300pxheight:300pxborder:1px solid #cccccctext-align:center">这里是文字</div>
解释说明:
1、<div></div>是一个闭合的标签,中间写你的内容,内容可以是文字,图片、链接等等
2、<div style="width:300pxheight:300pxborder:1px solid #cccccctext-align:center">是定义这个DIV的样式。
3、style 内写css样式。width是宽度,height是高度,border是凳拆慎边框。text-align:center是文字水平居中。
上面只是一个简单的例子,相信你应该枣敬能明白了DIV的简单局部和代码。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)