I have a simple ViewController to load FB comment plugins inside a UIWebView
@implementation ViewController - (void)viewDidLoad { [super viewDidLoad]; UIWebView * webView = [[UIWebView alloc] initWithFrame:CGRectMake(0, 0, 320.0f, 1505.0f)]; NSString * html = @"\ <!DOCTYPE html>\ <html xmlns:fb='http://ogp.me/ns/fb#'>\ <head>\ <meta name='viewport' content='width=device-width, initial-scale=1.0'>\ </head>\ <body style='background-color:red;'>\ \ <div id='fb-root'></div>\ <script>(function(d, s, id) {\ var js, fjs = d.getElementsByTagName(s)[0];\ if (d.getElementById(id)) return;\ js = d.createElement(s); js.id = id;\ js.src = 'http://connect.facebook.net/en_US/all.js#xfbml=1&appId=xxx';\ fjs.parentNode.insertBefore(js, fjs);\ }(document, 'script', 'facebook-jssdk'));</script>\ \ <fb:comments href='http://example.com' num_posts='10'></fb:comments>\ \ </body>\ </html>\ "; [webView loadHTMLString:html baseURL:nil]; [self.view addSubview:webView];
I can see that the comments are loading, but only the height is weird, it seems automatic resizing failed? I can view all comments if I use mobile safaris.

source share