0

我想在我正在制作的这个网页的底部有两列,但它们彼此重叠而不是彼此相邻。我究竟做错了什么?

这是html:

<!doctype html>
<html>
<head>
<meta charset=utf-8">
<title>Untitled Document</title>
</style>
<style type="text/css">
@import url("adobeIndex.css");
</style>
</head>

<body>
<div id="container">
<div id="banner">Content for  id "banner" Goes Here</div>
<div id="left-text">Content for  id "left-text" Goes Here</div>
<div id="1-left-column">Content for  id "1-left-column" Goes Here </div>
<div id="1-right-column"> Content for id "1-right-column" Goes Here</div>
</div>
</body>
</html>

和CSS:

    @charset "utf-8";
/* CSS Document */

#container {
width:968px;
background: #00F;
margin:auto;
padding-left:10px;
padding-right:10px;
overflow:hidden;
 }

#left-text {
 width:300px;
 height:400px;
 margin-top:20px;
 margin-bottom:20px;
}

#1-left-column, #1-right-column {
width: 464px;
float: left;
}
#1-right-column {
margin-left: 20px;
}
4

1 回答 1

2

不要以数字开头你的 id 名称,使用left-columnandright-columnone-left-columnandone-right-column代替

于 2012-06-24T17:28:17.387 回答