あなたはログインイベントに反応し、JavaScriptでDOMを編集することによってのようなボタンをリフレッシュすることができます。
ここで私はそれをやっています。
<div id="fblike" style="position:absolute; left:340px; top:80px;"></div>
<div id="fb-root"></div>
<script>
window.fbAsyncInit = function() {
FB.init({
appId : '135669679827333',
status : true, // check login status
cookie : true, // enable cookies to allow the server to access the session
xfbml : true, // parse XFBML
//channelUrl : 'https://anotherfeed.com/emo/channel.html', // channel.html file
oauth : true // enable OAuth 2.0
});
function onlogin(){
var loginb=document.getElementById('fblike');
loginb.innerHTML='';
loginb.innerHTML='<div id="fb-like"><fb:like
href="http://www.facebook.com/xxxxxx" send="true" width="450"
show_faces="false" colorscheme="dark"></fb:like></div>';
FB.XFBML.parse(loginb);
};
FB.Event.subscribe('auth.login', function(response) {
onlogin();
});
FB.Event.subscribe('auth.logout', function(response) {
//window.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#xfbml=1&appId=135669679827333";
fjs.parentNode.insertBefore(js, fjs); }(document, 'script',
'facebook-jssdk'));
</script>
ブリリアント!本当にありがとう。私はあなたが私の "JavaScriptペニー"をついに笑ったと思う。 – JamesG