css - Twitter Bootstrap 轮播的边框半径在 Chrome 浏览器上不起作用

标签 css twitter-bootstrap

twitter bootstrap carousel 的边框半径在 Firefox 和 IE9 上工作正常,但在 Chrome 浏览器上不起作用

<style>
.carousel{
    -moz-border-radius: 10px; /* FF1+ */
    -webkit-border-radius: 10px; /* Saf3-4, iOS 1+, Android 1.5+ */
    border-radius: 10px; /* Opera 10.5, IE9, Saf5, Chrome, FF4 */
    overflow:hidden;
}
</style>

<div id="myCarousel" class="carousel slide" >
    <!-- Carousel items -->
    <div class="carousel-inner">
        <div class="active item">
            <img src="img/1.jpg"/>
        </div>
        <div class="item">
            <img src="img/2.jpg"/>
        </div>
        <div class="item">
            <img src="img/3.jpg"/>
        </div>
    </div>
    <!-- Carousel nav -->
    <a class="carousel-control left" href="#myCarousel" data-slide="prev">&lsaquo;</a>
    <a class="carousel-control right" href="#myCarousel" data-slide="next">&rsaquo;</a>
</div>

最佳答案

我遇到了同样的问题并解决了增加 .carouselz-index

.carousel{
    -moz-border-radius: 10px; /* FF1+ */
    -webkit-border-radius: 10px; /* Saf3-4, iOS 1+, Android 1.5+ */
    border-radius: 10px; /* Opera 10.5, IE9, Saf5, Chrome, FF4 */
    overflow:hidden;
    z-index: 1000;
}

关于css - Twitter Bootstrap 轮播的边框半径在 Chrome 浏览器上不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11684550/

相关文章:

jquery - jQuery Colorbox 中视频下方的文本

css3 过渡 - 在过渡结束后设置属性

jQuery Bootstrap : "TypeError: ' undefined' is not a function (evaluating 'jQuery(' #myModal'). 模态 ('hide' )')

html - 如何仅在大型设备中添加表格样式

javascript - 查找上一行中的元素并更改类

php - WordPress - 将 .active 类添加到事件菜单项的子页面?

python - 无法在 Django 模板中加载 css

html - 字体下拉箭头不显示

jquery - Bootstrap轮播宽度比图片大

javascript - Bootstrap 按钮在单击时不会突出显示