Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div id="fb-root"></div>
- <script>
- window.fbAsyncInit = function() {
- FB.init({
- appId : '142859072412938',
- status : true, // check login status
- cookie : true, // enable cookies to allow the server to access the session
- xfbml : true, // parse XFBML
- //channelUrl : '', // channel.html file
- oauth : true // enable OAuth 2.0
- });
- FB.Event.subscribe('auth.login', function(response){
- location.reload();
- });
- FB.Event.subscribe('auth.logout', function(response){
- location.reload();
- });
- };
- // Load the SDK Asynchronously
- (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 = "//connect.facebook.net/en_US/all.js";
- fjs.parentNode.insertBefore(js, fjs);
- }(document, 'script', 'facebook-jssdk'));
- </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement