Add a Share button next to comments and comments on Facebook

I use the dialogue on the Facebook channel: http://developers.facebook.com/docs/reference/dialogs/feed/

Whenever I post something using it, Facebook adds two links below (like a comment):

enter image description here

However, when I see other entries in Timeline, I also see the Share link:

enter image description here

How can I instruct Facebook to also add this share link in the feed dialog?

+3
source share
3 answers

, , . , .

FB.ui(
   {
     method: 'feed',
     name: 'Facebook Dialogs',
     link: 'http://venu.com/',
     picture: 'http://venu.com/f8.jpg',
     caption: 'Venu site',
     description: 'asdasdasdasd.',
     message: 'asdasdasd!',
    actions: [
        { name: 'share', link: 'link here' }
      ]

   },
   function(response) {
     if (response && response.post_id) {
       alert('Post was published.');
     } else {
       alert('Post was not published.');
     }
   }
 );

/. , - , . URl.

, :)

[EDIT]

, "me/links" "me/feed". , , Facebook , . , . (https://developers.facebook.com/bugs/194522957295380)

$attachment = array(
    'access_token'=>TOKEN_HERE,
    'message'=>'message_here',
    'link' => 'http://www.example.com/',
);

$result = $facebook->api(
    'me/links',
    'post',
    $attachment
);

, . Facebook .

<head>
    <meta property="og:locale" content="en_US" />
    <meta property="og:site_name" content="name for ENTIRE SITE"/>
    <meta property="og:title" content="name of PAGE"/>
    <meta property="og:type" content="website"/>
    <meta property="og:image" content="<URL HERE>"/>
    <meta property="og:description" content="my description" />
    <title>Untitled</title>
</head>
+4

" " , . "" , ", . " Share ", , sharer.php (." URL- "" ).

+4

Like Button Sharer.php Share.

If you have a web page when a user clicks the Like button, they will send a link to their wall with a Share link.

In the canvas application, you can do something similar, although this will not work for feed messages that require dynamic text, such as a username or some value from their actions in the application.

0
source

All Articles