Skip to:
Content
Pages
Categories
Search
Top
Bottom

facebook connect to send post user profile

  • Avatar of Mascix
    Mascix
    Participant

    @mascix

    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 ;)

Viewing 7 replies - 1 through 7 (of 7 total)
  • Avatar of roydeanjr
    roydeanjr
    Participant

    @roydeanjr

    That is great, but what are the exact requirements to make this work?

    Avatar of Mascix
    Mascix
    Participant

    @mascix

    that piece of code already working under

    wp 2.8.5.2

    bp 1.1.2

    but I need to make that plugin otherwise at next update it will be overwritten. and I will probably forget to update that :)

    Avatar of Bowe
    Bowe
    Participant

    @bowromir

    I checked out your site but could not figure out what this does, could you please explain it a bit better? thanks :D

    Avatar of Mascix
    Mascix
    Participant

    @mascix

    you know these days a lot of blogs there are socializeable links. share this in twitter or share this in facebook stuff. and I assume that you know BuddyPress-Facebook Connect too.

    now we have blog posts and facebook connected users. when a facebook connected user publish a blog post it can be published on his/her facebook profile too. that piece of code make this happen when a user sends a blog post via wp admin panel.

    what I want to do is to make that code a plugin for wp or bp.

    @Bowe if you still did not understand just register guncesi.com with facebook account and create a blog and publish a post you will see the popup.

    Avatar of Bowe
    Bowe
    Participant

    @bowromir

    I understand now and it’s a good addition to the plugin! I would like to test it, but when I create a blog on your site the url testfacebook.guncesi.com does not seem to work.. Thanks for creating this, maybe someone else can help you add it to the FB Connect plugin or release it seperately!

    Avatar of Mascix
    Mascix
    Participant

    @mascix

    you just hit my isp’s problem time :) I called them and they were having problems about switch they got. anyway now it should work pls try it again =)

    Avatar of proshot
    proshot
    Participant

    @proshot

    I am having trouble getting Facebook to accept a buddy press page – of any sort but the biggest issue is the profile page.
    the symptoms are:
    facebook reads the url and does nto record the title
    but the page does have a title

    if you do have a page that does work I would love to see it and examine
    the code differences as it may help me discover the issue
    gus@proshotphoto.com

Viewing 7 replies - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.