Adding CSS to Facebook Like Box
I'm trying to add css styling to Facebook Like Box XFBML file but it doesn't take the stylesheet the regular way – its own stylesheet comes after yours. So I did some search and found posts that said to add css="youstylesheetlink.css" to the fb:like-box like this:
<fb:like-box href="https://www.facebook.com/example" width="496" height="120" show_faces="true" border_color="" stream="false" header="false" css="http://example.com/css/style.css?2"&开发者_Go百科gt;</fb:like-box>
But no matter what I try it doesn't take the stylesheet. Can anybody guide me how I can achieve this?
Thank you.
Facebook used to allow you to pass custom css to their like box, and that is why you see examples of it happening. But they stopped allowing you to do this for now.
If you could do it, it would be documented here.
IMHO, you cannot tinker with Facebook's corporate branding... they want a consistent user experience everywhere on the Internet, otherwise, you'll have people not trusting things that look like homemade "like" boxes.
Also see this...
Embedded Facebook Like-Box won't let me style it. Why?
Unless your website happens to have the same matching protocol, domain and port as the Facebook iframe
, you can not modify it because of Same Origin Policy.
精彩评论