这三列的顶端为何无法对齐?
<body>
<div id= "left "> 页面左列 </div>
<div id= "middle "> 页面中列 </div>
<div id= "right "> 页面右列 </div>
</body>
相应的CSS如下:
#left{ WIDTH:200px;
MARGIN: 0px;
TOP:0px;
}
#middle{ POSITION: absolute;
LEFT:220px;
TOP:0px;
WIDTH:300px;
MARGIN: 0px;
}
#right{ POSITION: absolute;
LEFT:530px;
TOP:0px;
WIDTH:280px;
MARGIN: 0px;
}
我发现左列比中、右列低一行的位置,不知为何,请高手帮忙解答,谢谢!!!
附:我用IE6.0
------解决方案-------------------- <style>
#left{
float:left;
MARGIN: 0px;
}
#middle{
float:left;
WIDTH:300px;
MARGIN: 0px;
}
#right{
float:left;
WIDTH:280px;
MARGIN: 0px;
}
</style>
<body>
<div id= "left "> 页面左列 </div>
<div id= "middle "> 页面中列 </div>
<div id= "right "> 页面右列 </div>
</body>
------解决方案-------------------- <body>
<div id= "left "> 页面左列 </div>
<div id= "middle "> 页面中列 </div>
<div id= "right "> 页面右列 </div>
</body>
<style type= "text/css ">
#left{
WIDTH:200px;
float:left;
}
#middle{
WIDTH:300px;
float:left;
}
#right{
WIDTH:280px;
float:left;
}
</style>