我的标题位于固定位置,但我遇到了 Disqus 问题。
我的情况: 我有一个不可移动的标题,每当我向下滚动时它都会保持在原位。我在底部的页脚之前有一个 div。该 DIV 包含 Disqus 评论系统。
问题是:
每当我在底部向下滚动时,DIV 都会按预期顺利运行(就在标题下方)但是Disqus 评论系统会超出预期的标题位于标题下方。
div的代码和评论模板的调用函数如下:
<div class="comments-template" style="position:inherit;">
<?php comments_template(); ?>
</div>
DIV和Disqus评论系统的CSS代码如下:
.comments-template{
width: 1040px;
position: static;
margin: auto;
clear:both;
background-color:#CCC;
}
#disqus_thread {
color: #FFF;
padding: 5px;
margin: auto;
clear:both;
position:static;
}
.dsq-comment-header {
background-color: 2d2d2d;
font-family:"Arial",sans-serif;
font-size: 12px;
height: 50px;
position:static;
clear:both;
}
.dsq-comment-message {
font-family:"Tahoma",sans-serif;
font-size: 11px;
color: #333;
}
textarea {
background-image: none;
background-repeat: repeat;
border: #666 2px solid; /* light blue border */
}
.dsq-comment {
border: #666 2px solid; /* light blue border */
margin-bottom: 15px;
}
希望您能帮我解决我的问题问题。
提前谢谢您!
My Situation:
I have a non moving header which stays in place whenever i scroll down. I have a div at the bottom just before the footer. This DIV contains the Disqus Commenting System.
The problem is:
whenever i scroll down at the bottom, the DIV run smoothly as expected (right under the Header) BUT the Disqus Commenting System GOES ABOVE the header which is supposed to be UNDER the header.
The code of div and the call function of comments template is right down below:
<div class="comments-template" style="position:inherit;">
<?php comments_template(); ?>
</div>
The CSS Codes for DIV and Disqus Commenting System is below:
.comments-template{
width: 1040px;
position: static;
margin: auto;
clear:both;
background-color:#CCC;
}
#disqus_thread {
color: #FFF;
padding: 5px;
margin: auto;
clear:both;
position:static;
}
.dsq-comment-header {
background-color: 2d2d2d;
font-family:"Arial",sans-serif;
font-size: 12px;
height: 50px;
position:static;
clear:both;
}
.dsq-comment-message {
font-family:"Tahoma",sans-serif;
font-size: 11px;
color: #333;
}
textarea {
background-image: none;
background-repeat: repeat;
border: #666 2px solid; /* light blue border */
}
.dsq-comment {
border: #666 2px solid; /* light blue border */
margin-bottom: 15px;
}
I hope you can help me with my problem.
Thank you in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
为您的标头提供更高的
z-index
:Give your header a higher
z-index
: