您的位置:首页 > 其它

页面抬头浮动广告简单实现方法

2008-08-29 15:15 811 查看
在页面抬头简单的使用了浮动条,可以应用在公告、广告文字宣传。

下载的一个网上代码,重新用DIV+CSS实现,去掉了Table.

请大家指点下这样写CSS是否合理,怎么样更简洁!

详细见代码! 代码下载

<html>

<head>

<title>爱煮饭</title>

<style type="text/css">

<!--

body { margin: 0px;padding: 0px;text-align: center;}

#izhufanCon {BORDER-BOTTOM: #e2e2e2 1px solid;COLOR: #333; height:25px;}

.title, .titleClose{

padding: 10px 0px 0px 0px;

}

.title{ float:left; padding-left:15px;}

.title a{

color: #333;

text-decoration: none;

font-size: 12px;

}

.titleClose{float:right;}

-->

</style>

</head>

<body>

<SCRIPT>

function toueme(){

document.getElementById("Izhufan").style.display="none";

}

</SCRIPT>

<DIV id=Izhufan>

<div id=izhufanCon >

<span class="title"><img src="images/kids.gif" width="15" height="14">

<a href="www.izhufan.cn"> 爱煮饭,我煮饭,为爱煮饭</a></span>

<span class="titleClose">

<a style="CURSOR: hand" onClick=toueme()><img

src="images/close.gif" width=84 height=11 hspace="6" border=0></a>

</span>

</div>

</DIV>

</body>

</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: