首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >以不同的风格显示facebook评论?

问以不同的风格显示facebook评论?
EN

Stack Overflow用户
提问于 2015-04-17 00:21:54
回答 1查看 979关注 0票数 0

我想在网页上显示facebook评论,但facebook评论插件是facebook风格的。是否可以删除除facebook评论文本之外的所有内容?

或者有没有其他的js/jquery插件或者代码可以只拉取facebook的评论,这样我就可以显示它们了。

任何帮助或提示都是非常感谢的!

EN

回答 1

Stack Overflow用户

发布于 2015-04-17 06:06:56

好吧,正如我上面所说的,这里有一个例子解释了我认为你是如何做到的。显然,这是有限的,但也是有用的:

jsFiddle here

代码语言:javascript
复制
// HTML

<div class="relative">
    <div class="overlap">
        <div class="box a"><p>You have to imagine that this is the facebook plugin</p></div>
        <div class="box b"></div>
        <div class="box c">IPSUM dolor and sit then amet</div>
        <div class="box d"></div>
        <div class="box e"></div>
    </div>
    <iframe scrolling="no" src="http://en.lipsum.com"></iframe>
</div>
<br />
<input type="button" value="show/hide overlaps" />


// CSS

*:not(input) { margin: 0; padding: 0; }
iframe { width: 350px; height: 350px; overflow: hidden; border: solid 1px lightblue; }
.relative { position: relative; width: 350px; height: 350px; } 
.overlap { display: none; position: absolute; width: 100%; height: 100%; top: 1px; left: 1px; }
.box { position: absolute; background: white; text-align: center; }

.a { left: 0; width: 100%; height: 105px; background: lightgreen; }
.a p { font: normal 14px/105px Tahoma, sans-serif; color: #666; }
.b { left: 0; bottom: 0; width: 57px; height: 114px; }
.c { left: 108px; bottom: 90px; width: 225px; height: 20px; font: normal 15px Arial, sans-serif; color: red; text-align: left; }
.d { left: 0; bottom: 0; width: 100%; height: 87px; background: lightgreen; }


// JS

$('input').on('click', function(){
    $('.overlap').fadeToggle();
});
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/29680614

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档