Created
April 4, 2012 15:19
-
-
Save kitsunde/2302593 to your computer and use it in GitHub Desktop.
Facbeook snippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<link rel="stylesheet" href="/static/styles/reset.css"> | |
</head> | |
<body> | |
<div id="fb-root"></div> | |
<script> | |
window.fbAsyncInit = function () { | |
FB.init({ | |
appId:'{{ app_id }}', | |
status:true, | |
cookie:true, | |
xfbml:true | |
}); | |
FB.Canvas.setAutoGrow(); | |
}; | |
//Load the SDK asynchronously | |
(function () { | |
var e = document.createElement('script'); | |
e.async = true; | |
e.src = document.location.protocol + | |
'//connect.facebook.net/en_US/all.js'; | |
document.getElementById('fb-root').appendChild(e); | |
}()); | |
</script> | |
</body> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script> | |
<script> | |
var _gaq = _gaq || []; | |
_gaq.push(['_setAccount', 'UA-12538895-10']); | |
_gaq.push(['_trackPageview']); | |
(function () { | |
var ga = document.createElement('script'); | |
ga.type = 'text/javascript'; | |
ga.async = true; | |
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; | |
var s = document.getElementsByTagName('script')[0]; | |
s.parentNode.insertBefore(ga, s); | |
})(); | |
</script> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment