2

是的,就像标题一样,Facebook 评论插件在滚动时会覆盖我的标题 div。

这是滚动之前: 在此处输入图像描述

这是滚动 后:在此处输入图像描述

标题栏样式

#header {
    height:45px;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0.95;
    background: #2D2D2D;
}
#colorbars {
    border-top: 3px solid #DD5044;
    height:42px;
    border-bottom: 8px solid rgba(40, 40, 40, .2);
}
#headercontainer {
    width: 940px;
    overflow: hidden;
    margin: 0 auto 0 auto;
}

标题栏的HTML

<div id="header"><header id="colorbars"><div id="headercontainer">
// content
</div></header></div>

Facebook插件的代码是:

<fb:comments href="<?php echo $facebook_href; ?>" width="655" num_posts="4"></fb:comments>
4

1 回答 1

0

设置z-index标题有帮助吗?

#header {
    /* ... */
    z-index: 9999;
}
于 2012-12-22T22:28:34.603 回答