Facebook Widget Height and Width Settings Overwritten by Inline CSS
-
I set the width and height in the FB widget to be 325px by 400px and it is overwritten by inline css to display at 185px x 130px. Why doesn’t it accept the widget settings?
-
Jetpack itself doesn’t add that inline CSS. It’s most likely added by your theme, to make sure the widgets to break the sidebar layout.
Could you post your site URL here, so I can have a look?
If you want it to remain private, you can also contact us via this contact form:
http://jetpack.me/contact-support/Jeremy thanks for your speedy response. Sorry mine wasn’t quicker.
The site is in development here: http://pcreativedesign.com/ the Facebook like box is in a footer widget.
Thanks!
Could you let me know what your widget settings are? Do the “325px” and “400px” remain when you save the widget settings, or do they changed to 185px and 130px?
Jeremy, yes, the settings remail at 325 x 400 in the widget settings. Screenshot here if interested: http://pcreativedesign.com/wp-content/uploads/2016/01/FB-Plugin-Settings.png
Thanks I appreciate you looking into this.
Thanks!
It appears that Jetpack outputs the right values, as you can see when looking at your site’s source code:
http://i.wpne.ws/ez0vFacebook’s JavaScript library, however, overwrites those values:
http://i.wpne.ws/ezY2This is most likely because Facebook’s Page Plugin is built to adapt its width to the width of the widget container.
To test that theory, you could try to increase the width of that container by adding the following to your theme stylesheet or to your custom CSS editor available under Appearance > Edit CSS in your dashboard:@media (min-width: 981px) { .widget_facebook_likebox { width: 325px; } }
Let me know how it goes.
Jeremy, That did the trick. Sorry again for my delay, I didn’t see the notification that you posted. I very much appreciate your assistance.
Have a great weekend!
- The topic ‘Facebook Widget Height and Width Settings Overwritten by Inline CSS’ is closed to new replies.