I was having some facebook script error in IE8 while doing rendering test for site compatibility so I took a look in index.php and found something strange.
In the header, I found this.
<html xmlns:fb="http://www.facebook.com/2008/fbml" xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->language; ?>"
At the bottom of index.php, i found this.
<div id="fb-root"></div>
<script type="text/javascript">
/* <!;
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_US/all.js#xfbml=1&appId=332885830182";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
/* ]]> */
</script>
What exactly are those code there for? And why does the script at the bottom has a appID? I did some digging into the files and I think this code is only required for the insertion of fb-comment in normal joomla articles?
So for ppl who uses K2 or disable the fb-comment box in normal joomla articles, we don’t really need this code right in index.php right? Removing it seems to help with loading speed though that might be psychological.