我是靠谱客的博主 繁荣百褶裙,这篇文章主要介绍CSS 隐藏滚动条,现在分享给大家,希望可以做个参考。

http://jsfiddle.net/5GCsJ/18807/

 

<div id="outer">
  <div id="inner">
    hello无论如何我都想<br/>hello无论如何我都想<br/>
    hello无论如何我都想要<br/>hello无论如何我都想<br/>
    hello无论如何我都想要对<br/>hello无论如何我都想<br/>
    hello无论如何我都想要对你<br/>hello无论如何我都想要对你<br/>
    hello无论如何我都想<br/>hello无论如何我都想要对你<br/>
    hello无论如何我都想要<br/>
    hello无论如何我都想要对<br/>
    hello无论如何我都想要对你<br/>
  </div>
<div>


#outer{
    height: 200px;
    width: 300px;
    border: 1px solid green;
    overflow: hidden;
}

#inner{
    height: 100%;
    width: 100%;
    border: 1px solid blue;
    overflow: auto;
    padding-right: -15px;
}

或者

#inner{
    height: 100%;
    border: 1px solid blue;
    overflow: auto;
    margin-right: -15px;
}

最后

以上就是繁荣百褶裙最近收集整理的关于CSS 隐藏滚动条的全部内容,更多相关CSS内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(60)

评论列表共有 0 条评论

立即
投稿
返回
顶部