I'm using the Facepile plugin on a dark background, which is supposedly supported behavior, but when the viewer is not logged in to Facebook, the Facepile iframe just becomes a white rectangle.
It would look fine on a white background, but looks horrible on a dark one.
Everything looks fine if the user is logged in to Facebook. If the viewer has friends that have liked the site, they show up with the dark background showing up behind them. If the viewer has no friends that like the site, the facepile iframe is a transparent rectangle, which looks fine.
It's just broken when the viewer is not logged in to facebook.
Is there any way to fix this?
Unfortunately there is no way to fix this yourself. In the stylesheet Facebook references, there is this line:
body{background:#fff;font-size: 11px;font-family:"lucida grande",tahoma,verdana,arial,sans-serif;color:#333;line-height:1.28;margin:0;padding:0;text-align:left;direction:ltr;unicode-bidi:embed}
There is this hard coded background color which cannot be overridden. The only option is waiting for Facebook to fix this bug.
Facebook fixed this on 25 Nov 2011.
来源:https://stackoverflow.com/questions/7290069/facepile-iframe-is-white-when-the-viewer-is-not-logged-in-to-facebook