div框宽高如何设置

来源:百度知道 编辑:UC知道 时间:2024/06/06 20:13:03
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

<meta http-equiv="content-type" content="text/html;charset=gb2312">
<!--把下面代码加到<head>与</head>之间-->
<style type="text/css">
*{margin:0;padding:0;}
html{height:100%;margin-bottom:1px;background:#48494d;}
body{margin:0;padding:0 0 10px; background:url(image/board.jpg);font-size:62.5%;}
body,td,input,textarea,select{color:#666;font-family:Arial,Tahoma,sans-serif;}
.fl{float:left;}
.fr{float:right;}
.clear{clear:both;height:0;margin:0;}
.clearfix:after{con

#t3{background:url(image/m_bg_nav.gif) #a3a19c 0 100% repeat-x;border-top:0.1em solid #dedede; width:904;}

#t3n{width:904px;margin:0 50px;padding:0;list-style:none;}

这两个地方加上高度即可,如:
#t3{background:url(image/m_bg_nav.gif) #a3a19c 0 100% repeat-x;border-top:0.1em solid #dedede; width:904;height:150px;}

#t3n{width:904px;margin:0 50px;padding:0;list-style:none;height:150px;}