简体   繁体   English

是否有可能给Facebook页面插件圆角?

[英]Is it possible to give the Facebook page plugin rounded corners?

I'm using the Page Plugin from Facebook which displays a Facebook page feed on a website. 我正在使用Facebook的页面插件,它在网站上显示Facebook页面提要。 The plugin is only a small amount of HTML code that goes into whatever file your using to make your website. 该插件只是少量的HTML代码,可以存入您用于制作网站的任何文件。

This is the code: 这是代码:

<div class="fb-page" data-href="https://www.facebook.com/pages/UrchinBooks-Shop/922785527788785?fref=ts" data-width="250" data-height="340" data-small-header="false" data-adapt-container-width="true" data-hide-cover="false" data-show-facepile="true" data-show-posts="true"><div class="fb-xfbml-parse-ignore"><blockquote cite="https://www.facebook.com/pages/UrchinBooks-Shop/922785527788785?fref=ts"><a href="https://www.facebook.com/pages/UrchinBooks-Shop/922785527788785?fref=ts">UrchinBooks Shop</a></blockquote></div></div>

I've tried using the classes of the div's in my stylesheet but that doesn't do anything. 我已经尝试在我的样式表中使用div的类,但是没有做任何事情。 I also tried to add a style tag to all the div's as well. 我还尝试为所有div添加样式标记。 Nothing there either. 那里也没有。

Is it possible to give the box that displays on the webpage, the one that's generated by the plugin, rounded corners? 是否可以提供在网页上显示的框,即插件生成的框,圆角?

This is how to give the plugin rounded corners; 这是如何给插件圆角;

Go into the developer tools in your browser and go through the HTML until you find the place where the HTML code for the plugin is located. 进入浏览器中的开发人员工具并浏览HTML,直到找到插件的HTML代码所在的位置。 Expand all the div's, spans and anything else until you find the iFrame tag. 展开所有div,span和其他任何内容,直到找到iFrame标记。 You will need to use this iFrame tag in your stylesheet. 您需要在样式表中使用此iFrame标记。 For me it was: 对我来说是:

.fb_iframe_widget iframe

but it may be different for other people as the plugin may work differently. 但对于其他人来说可能会有所不同,因为插件可能会有不同的工作方式。

Basically, you use that iFrame in your stylesheet. 基本上,您在样式表中使用该iFrame。 For me, I used the developer tools to find the iFrame tag, then I found a CSS selector associated with that iFrame tag, and I used that CSS selector in my stylesheet. 对我来说,我使用开发人员工具查找iFrame标签,然后我找到了与该iFrame标签关联的CSS选择器,并在样式表中使用了该CSS选择器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM