• 01-09-2009, 15:30:18
    #1
    Merhaba arkadaşlar,

    Facebook uygulaması geliştirmeye ve öğrenmeye çalışıyorum bi yerde takıldım. Uygulamayı kullanan kullanıcıların profilinde,

    Mehmet xxx uygulamasını kullanıyor..
    Mehmet xxx oynadı.
    Mehmet xxx e çiçek gönderdi.

    Bu tarz yazılar çıksın istiyorum bunun için ne yapabilirim, yardımcı olan arkadaşlara şimdiden teşekkürler...
  • 01-09-2009, 23:04:28
    #2
    Yok mu bi bilgisi olan
  • 02-09-2009, 16:57:09
    #3
    Eposta Aktivasyonu Gerekmekte
    aynı sorunu bende yaşıyorum

    facebook wikiden buluğum bir kod var fakat bu kodu nerede kullanacağımı bilmiyorum. Yardımlarınızı bekliyorum??
    <?php
    ///////////start header for each page in your application if u have other remove it//////////////////////////
    require_once 'facebook.php';
    $appapikey = 'xxx';
    $appsecret = 'xxx';
    $appcallbackurl = 'xxx';  // http://www.yourdomain.com/yourfolder
    $facebook = new Facebook($appapikey, $appsecret);
    $user = $facebook->require_login();
    try {
    // If app is not added, then attempt to add
    if ($facebook->api_client->users_isAppAdded($user)) {
    exit;
    }
    } catch (Exception $ex) {
    $facebook->set_user(null, null);
    $facebook->redirect($appcallbackurl);
    }
    ///////////end header for each page in your application if u have other remove it//////////////////////////
    $template_bundle_id = xxx;   // change 123456789 with ur Template Bundle ID
    $tokens = array( 'album'=>'Play' ); 
    //There is no target for the story in this example, but if there was, 
    //$target_ids would be an array of user IDs 
    $target_ids = array(); 
    $body_general = ''; 
    $facebook->api_client->feed_publishUserAction( $template_bundle_id, json_encode($tokens), implode(',', $target_ids), $body_general);
    ?>
  • 02-09-2009, 17:10:37
    #4
    daha çok beklersin
    bekleriz...
    beklerler...
  • 02-09-2009, 18:56:49
    #5
    Ne bekliyorsunuz beyler?
    Bir kod soruyorsunuz. Bir kod yazmay abaşlamış ve bir yerde takılmış değilsiniz.
    Siz komple bir kodun nasıl yazılacağını soruyorsunuz.
    Video sitesi nasıl yazarım demek gibi bir şey bu.
    1 dakika aradım bir ton kaynak buldum. siz nasıl bulamıyorsunuz anlamıyorum.
    Buyrun örnek buradakine bakıp kendi sitenize uyarlayın.

    $title = ‘Your <a href=”http://apps.facebook.com/dummies/recipes?14231”>Buried
    Treasure Dip recipe</a> has been approved and is ready for
    sharing’;
    $story = ‘We just wanted to let you know that Chef Cosma Crammer loved your
    recipe so much that he has stolen your idea and called it his own
    for his upcoming book <i>Best Recipes I Never Knew</i>.’;
    $image1 = ‘http://richwagnerwords.com/facebook/rimages/14231.jpg’;
    $image1_link = ‘http://apps.facebook.com/dummies/recipes?14231’;
    $success = $facebook->api_client->feed_publishStoryToUser($title, $story,
    $image1, $image1_link);
    Kullanılanbilen classlar
    feed_publishStoryToUser
    feed.publishActionOfUser
    feed.publishTemplatizedAction
    notifications.send

    Buna göre düzenleyeceksin işte. Her class ile ilgili daha detaylı bilgi ver örnek kod bulursun. Uyarı gönderen classlar bunlar.
  • 15-10-2009, 10:46:20
    #6
    Üyeliği durduruldu
    evet dostum her class ıle ılgılı ornek var fakat orneklerın hepsınde hata cıkıyor
    senın verdıgın ornek dahıl ınternette kaynak cok fakat bır cogu olmus eskı surum kodlar dolanıyor.

    Hala aramaktayım bu classların hıcbırını calıstıramadım
    notıfıcatıon.send harıc
  • 23-10-2009, 19:37:59
    #7
    Öncelikle bir TemplateBundle oluşturmalısın. (Buradan)
    Daha sonra oluşturduğun bu TemplateBundle ID numarası verilecek sana atıyorum 123456 olsun. Aşağıdaki kodlarla o Bundle profile gönderilir.

    //You get this id when you call registerTemplateBundle
     $template_bundle_id = 123456;
    $tokens = array(
    'album'=>'The White Album',
    'artist'=>'The Beatles',
    'images'=>array(array('src'=>'http://example.com/WhiteAlbum.jpg', 'href'=>'http://example.com/WhiteAlbum.htm'))
    );
    //There is no target for the story in this example, but if there was,
    //$target_ids would be an array of user IDs 
    $target_ids = array();
    $body_general = '';
    $facebook->api_client->feed_publishUserAction($template_bundle_id, $tokens , implode(',', $target_ids), $body_general);
    Kodlar Facebook Developers Wiki içersinden alınmıştır.