Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html xmlns:fb="https://www.facebook.com/2008/fbml">
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
- <title>Facebook Like To Download</title>
- <script src="//connect.facebook.net/en_US/all.js"></script>
- </head>
- <body >
- <div id="fb-root"></div>
- <script>
- window.fbAsyncInit = function() {
- // init the FB JS SDK
- FB.init({
- appId : '361332261230650317', // App ID from the app dashboard
- status : true, // Check Facebook Login status
- xfbml : true // Look for social plugins on the page
- });
- FB.getLoginStatus(function(response) {
- if (response.status === 'connected') {
- alert('connected');// connected
- } else if (response.status === 'not_authorized') {
- alert('not_authorized');// not_authorized
- logout();
- login();
- } else {
- alert('not_logged_in');// not_logged_in
- login();
- }
- });
- // Additional initialization code such as adding Event Listeners goes here
- };
- function logout() {
- FB.logout(function(response) {
- // user is now logged out
- });
- }
- function login() {
- FB.login(function(response) {
- if (response.authResponse) {
- // connected
- } else {
- // cancelled
- }
- }, {scope: 'email,publish_actions'});
- }
- // 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>
- <center>
- <h1 style="color:#136697;margin-top:180px;">LIKE OUR FACEBOOK PAGE TO DOWNLOAD SCRIPT</h1>
- <div id="like">
- <fb:like href="http://www.facebook.com/pages/MYPAGE/112342345221704090" send="false" width="50" show_faces="false"></fb:like>
- </div>
- <div id="login">
- </div>
- </center>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement