/* Vanilla JS */
function setupFBframe(frame) {
var container = frame.parentNode;
var containerWidth = container.offsetWidth;
var containerHeight = container.offsetHeight;
var src =
"https://www.facebook.com/plugins/page.php" +
"?href=https%3A%2F%2Fwww.facebook.com%2Ffacebook" +
"&tabs=timeline" +
"&width=" +
containerWidth +
"&height=" +
containerHeight +
"&small_header=false" +
"&adapt_container_width=false" +
"&hide_cover=true" +
"&hide_cta=true" +
"&show_facepile=true" +
"&appId";
frame.width = containerWidth;
frame.height = containerHeight;
frame.src = src;
}
/* begin Document Ready
############################################ */
document.addEventListener('DOMContentLoaded', function() {
var facebookIframe = document.querySelector('#facebook_iframe');
setupFBframe(facebookIframe);
/* begin Window Resize
############################################ */
// Why resizeThrottler? See more : https://developer.mozilla.org/ru/docs/Web/Events/resize
(function() {
window.addEventListener("resize", resizeThrottler, false);
var resizeTimeout;
function resizeThrottler() {
if (!resizeTimeout) {
resizeTimeout = setTimeout(function() {
resizeTimeout = null;
actualResizeHandler();
}, 66);
}
}
function actualResizeHandler() {
document.querySelector('#facebook_iframe').removeAttribute('src');
setupFBframe(facebookIframe);
}
})();
/* end Window Resize
############################################ */
});
/* end Document Ready
############################################ */
@import url('https://fonts.googleapis.com/css?family=Indie+Flower');
body {
font-family: 'Indie Flower', cursive;
}
.container {
max-width: 1170px;
width: 100%;
margin-left: auto;
margin-right: auto;
}
.content {
overflow: hidden;
}
.left_sidebar {
position: relative;
float: left;
width: 30%;
max-width: 300px;
}
.main_content {
position: relative;
float: left;
width: 70%;
background-color: #DDEFF7;
}
/* ------- begin Widget Facebook -------------- */
.widget--facebook--container {
padding: 10px;
border: 1px solid #000;
}
.widget-facebook {
height: 500px;
}
.widget-facebook .facebook_iframe {
border: none;
}
/* ---------- end Widget Facebook---------------- */
/* ----------------- no need -------------------- */
.block {
color: #fff;
height: 300px;
background-color: #00A7F7;
border: 1px solid #005dff;
}
.block h3 {
line-height: 300px;
text-align: center;
}
<!-- Min. responsive 180px -->
<div class="container">
<div class="content">
<div class="left_sidebar">
<aside class="block">
<h3>Content</h3>
</aside>
<!-- begin Widget Facebook
========================================= -->
<aside class="widget--facebook--container">
<div class="widget-facebook">
<iframe id="facebook_iframe" class="facebook_iframe"></iframe>
</div>
</aside>
<!-- end Widget Facebook
========================================= -->
<aside class="block">
<h3>Content</h3>
</aside>
</div>
<div class="main_content">
<h1>Responsive width Facebook Page Plugin</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laborum earum, temporibus, maxime repudiandae obcaecati veritatis, odio dolore provident tenetur perferendis ipsam, rem esse vitae laudantium voluptatem iste aliquam optio ab.</p>
</div>
</div>
</div>
#u_0_0
element seems to be the problem, and as it's created within the facebook iframe I don't think it's possible to manipulate it — not even with javascript. – Galipot