Created
October 11, 2010 16:01
-
-
Save joshjhall/620761 to your computer and use it in GitHub Desktop.
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 xmlns='http://www.w3.org/1999/xhtml' | |
xmlns:fb='http://www.facebook.com/2008/fbml' | |
lang='en'> | |
<head> | |
<script type='text/javascript'> | |
// Block you'll need the IE8 debugger turned on or the console.log() events will cause errors | |
console.log('+++started page load'); | |
</script> | |
</head> | |
<body> | |
<script type='text/javascript' src='http://connect.facebook.net/en_US/all.js'></script> | |
<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js'></script> | |
<div id='fb-root'></div> | |
<div id='test'></div> | |
<script type='text/javascript'> | |
console.log('Begin FB init'); | |
FB.init({ | |
appId : '....', | |
status : true, // check login status | |
cookie : true, // enable cookies to allow the server to access the session | |
xfbml : true // parse XFBML | |
}); | |
console.log('End FB init'); | |
FB.getLoginStatus(function(response) { | |
console.log(response.status); | |
$.post( | |
'/tmp/json/', | |
{}, | |
function(data) { | |
console.log('Loading JSON data'); | |
$('#test').html(data.html+response.status); | |
}, | |
"json" | |
); | |
}); | |
console.log('+++finished page load'); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment