facebook connect to send post user profile
-
I just made some edit on edit-form-advanced.php to open facebook popup to send user’s profile and its working. but I dont know how to make this a plugin for wordpress.
here is the code:
<?if($post_ID>0){?>
<script src=”http://static.ak.connect.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php/tr_TR” type=”text/javascript”></script>
<script language=”javascript”>
FB.init(“977db444b8e3dc1eb9497708f2a1a004″,”/xd_receiver.htm”,
{“reloadIfSessionStateChanged”: true,”ifUserNotConnected”:onFBNotConnected,”ifUserConnected”:onFBConnected});
var attachment ={‘name’‘<?=$post->post_title?>’,’href’‘<?=get_permalink($post_ID)?>’,’description’“Kaynak:http://www.guncesi.com | <?= _e(‘Author’) ?> Link:<?=get_permalink($post_ID)?>”};
function onFBConnected(){
FB.ensureInit(
function() {
FB.Connect.streamPublish(‘<?=$post->post_title?>’, attachment,null,null,”Ekleyecekleriniz?”,null,true);
}
);
}
function onFBNotConnected() {
}
</script>
<?}?>
you can try it with http://www.guncesi.com login with facebook
- The topic ‘facebook connect to send post user profile’ is closed to new replies.