溢出在Opera 28中不起作用

时间:2015-04-20 12:27:20

标签: css overflow opera opera-blink

有谁知道为什么Opera不使用overflow:hidden

左边是Opera,右边是Firefox enter image description here

CSS:

#ChatBig {
    width: 60%;
    height: 600px;
    margin: auto;
    background-color: white;
    overflow:hidden;
    resize:none;
    position: relative;
    border: 1px solid #000;
}
#ChatMessages{
    width: 100%;
    min-height: 498px;
    font-size: 16px;
    font-weight: normal;
    overflow:hidden;
    resize:none;
    position: absolute;
    bottom: 50px;
    margin-bottom: 10px;
}
#ChatText{
    width: 100%;
    height: 50px;
    border: 1px solid #000;
    overflow:hidden;
    resize:none;
    position: absolute;
    bottom: 0;
}

1 个答案:

答案 0 :(得分:0)

试试这个:

#ChatBig {
    width: 60%;
    height: 600px;
    margin: auto;
    background-color: white;
    overflow:hidden;
    resize:none;
    position: relative;
    border: 1px solid #000;
}
#ChatMessages{
    width: 100%;
    min-height: 498px;
    font-size: 16px;
    font-weight: normal;
    overflow:hidden;
    resize:none;
    position: absolute;
    bottom: 50px;
    margin-bottom: 10px;
}
#ChatText{
    width: 100%;
    height: 50px;
    border: 1px solid #000;
    overflow:hidden;
    resize:none;
    position: absolute;
    bottom: 0;
}
<div id="ChatBig">
    <div id="ChatMessage">
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        A line of chat<br/>
        ...
    </div>
    <textarea id="ChatText">
    </textarea>
</div>