0

http://jsfiddle.net/vrJr9/

in the above jsfiddle you can see my shadow is not good, I edited a comment in the css where you can uncomment out and see what it suppose to look like with content: url(). I currently have 2 dilemmas, first I can use content: url() to get the correct look, but then the black image gets covered. Or I can use background: url() and the black placeholder image doesn't get covered up but my transparent shadow thingy will look like crap. so if I can fix one of the problem i'm good to go.

Here is the code:

<div class="list_carousel">
    <ul id="foo2">
        <li>
          <a href="#"><img src="http://dummyimage.com/158x228/000/fff.png"></a>
        </li>
    </ul>
    <div class="clearfix"></div>    <a id="prev2" class="prev" href="#"><img src="image/images/carousel_control_03.png"/></a>
    <a id="next2" class="next" href="#"><img src="image/images/carousel_control_05.png"></a>

    <div id="pager2" class="pager"></div>
</div>

Here is the css:

.list_carousel {
    background-color: #fff;
    margin: 0 76px 30px 76px;
    width: 808px;
}
.list_carousel ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: block;
}
.list_carousel li {
    font-size: 40px;
    color: #999;
    text-align: center;
    background-color: #fff;
    border: 5px solid #fff;
    width: 180px;
    height: 250px;
    padding: 0;
    margin: 6px;
    display: block;
    float: left;
    background: url(http://i.imgur.com/jahcmyA.png) no-repeat 50% 100%;
    /* content: url(http://i.imgur.com/jahcmyA.png) */
}
4

1 回答 1

0

好的,我明白了为什么我使用背景时难看的透明度: url (); 这是因为我有一个 5 像素的边框,可以将所有内容都切掉,所以它使透明度看起来像有方形边缘,而且我试图插入的图片太大。一旦我调整了这两个设置,一切看起来都干净漂亮。

于 2013-08-22T18:35:33.810 回答