【发布时间】:2013-11-30 02:26:43
【问题描述】:
我有以下代码:
<html>
<head>
<style>
#wrapper {
width:100%;
height:1000px;
border:1px solid #000000;
}
#right {
position:fixed;
top: 10px;
float:right;
width:200px;
height:100px;
border:1px solid #000000;
}
</style>
</head>
<body>
<div id="wrapper">
<div id="right"></div>
</div>
</body>
</html>
在使用固定定位时,如何让right 元素浮动到包装器的右侧?
【问题讨论】:
-
你不能浮动一个固定的元素,它在文档流之外所以没有意义!