Featured on Meta To make it true responsive add this to your CSS:This will cause the plugin to adapt to the currently availably space when you resize the browser If you are using the official wordpress facebook plugin due to the mobile sniffing facebook do.The mobile version will automatically show up when a mobile device If preferred, you can still control the width via a

I think it's a small bug of the new fb feature.Unlike Twitter widgets, it seems that at least Facebook Page plugin is not responsive. container element.

//fb_iframe_widget_fluid is added in same situation, but only for mobile devices (tablets, phones) //By removing those classes FB.XFBML.parse() will reset the plugin widths. This will load the width of what's available to the plugin at loading time. You may need !Joining the uninformed masses with my own solution to this problem, as of September, 2015:Wait for Facebook to expose more of the widget API so we can see what the hell is going onThis is JQuery and might be part of the answer to your question. By using our site, you acknowledge that you have read and understand our It doesnt seem to like percentages and doesnt see the size of the box it's in so this isnt working.

Save Button. Facebook now sets the width of a div inside the iframe.good to know... thanks! Set iFrame Height To Fit Its Content - jQuery frameLoader.

Because I tried your code but It is not working.data-width does not allow any percentage. On some websites I've used this CSS code to make the plugin responsive inside a element:My Page plugin code looks like this (not providing a data-width attribute):It looks like Facebook has added a div element with a inline style element within the DOM loaded by the iframe:When I adjust this width to 100%, every element is aligned at the full width except the cover photo.It is possible to give this new Page plugin a responsive behavior just like with the Like box plugin?Unlike like-box, this plugin enforces its limits by sticking to the boundary values if mis-configured.When rendering on smaller screens, enforce desiered The plugin renders at a smaller width (to fit in smaller screens) automatically, if the container is of slimmer than the configured You can scale down the container on mobile and the plugin will fit in as long as it gets the minimum of This doesn't work too well when you have the plugin placed in a thin column, like a sidebar for example. behavior.

im toying with doing @media queries to resize it depending on the size of browser window. if you're asking this question in 2015, this is the answer.This did not work for me. When you resize the browser window the plugin will remain at that initial width.

Email Web: Save Button. The CSS code of Alan and Jubair is commented in the code.I've just tried this and it appears there is now a EDIT: You can't access the iframe content with JS because it's coming from another domainCreate an empty div where you want the facebook like box to be (or other social plug-in, works universally) with a class 'fb-container', then add the following jQuery:I got it working using a little jQuery and setting the "data-width" attribute when the page loads and on window resizing. I'm developing a site around the "responsive design" concept, but the facebook social plugins are static width and "break" the layout when it's re-sized.Using media queries, I've set the plugins to hide on low-res browsers (mobile, etc...).

The Overflow Blog The Page plugin lets you easily embed and promote any public Facebook Page on your website.

width parameter, and instead has a fluid width of 100% in order to And worked like a charm.Please not that the 'accepted answer' that didn't work in 2013 is no longer the accepted answer. Problem I ran into with all the CSS approaches is that some of the comments and buttons were hidden outside the container's margins or overflowing.Here's my $0.02, hope it helps. Should I edit this answer accordingly?Does this work with the new facebook code, considering that a div now has a set width inside the iframe?This no longer works either. Facebook iframe's inner content has fixed width 340px which still doesn't change.This cuts the content off from the right side, when the container is resized narrower.Worked like a charm, twentyfortysix! Facebook now sets the width of a div inside the iframe.That might have worked in the past, but facebook has updated their code, so this no longer works.Wonder if that is a new capability? Facebook sets the width of an ID with the name starting with "feeback_" inside the iframe, which you can't alter. I agree with @Gavin. Docs are jQuery Plugin To Auto iFrame Height Adjusting - autoHeight.js. it should be fixed numbers. Facebook introduced a new Page Plugin to replace the Like box plugin.I'm replacing the Like Box plugin with this new plugin.

I'll test later. But, if you make the Just put this either in your CSS file or in your html code with style tags !! When placing it in bootstrap site it does not scale with the bootstrap column resizingI dont see how this is possible, as there is a div class="_2p3a" that is inside the iframe with width set and you cant override cross domain iframe css ??! I am new at this, so I am not sure if this is the most elegant solution to making the like button repsonsive. You

#fbSEOComments, #fbSEOComments iframe[style] {width: 100% !important;} This doesnt always do the trick im learning. Facebook now sets the width of a div inside the iframe.this works for me but i have changed .fb-like to .fb-like-box because my container is .fb-like-box.it's a pity this is still static though. Free 30 Day Trial