1.圆角:
border-radius:16px 16px 16px 16px;
2透明度:
filter: alpha(opacity=80);
opacity: 0.8;
3. div内文本自动换行:
<style type="text/css">
<!--
/* 自动换行 */
.atuo_break_line {
white-space: pre-wrap; /* css-3 */
white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
white-space: -pre-wrap; /* Opera 4-6 */
white-space: -o-pre-wrap; /* Opera 7 */
word-wrap: break-word; /* Internet Explorer 5.5+ */
}
-->
</style>
<div class="atuo_break_line" style="width:80px">xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</div>
4. IE6 IE7实现 inline-block
例如:
.div_rate
{
width: 80px;
height: 10px;
border: 1px solid lightgray;
background-color: transparent;
overflow: hidden;
display: inline-block;
}
.div_rate {
_zoom:1;
*display: inline;
}
hack代码单独写在一个css样式中即可
时间: 2024-10-01 06:21:44