1

I'm trying to do a post similar to those of Giphy with gif loop. To begin using the Graph API Explorer, I tried to post a gif using the "source field" but the results as is unsatisfactory

Rikesh
  • 26,156
  • 14
  • 79
  • 87
4z5ipxedey
  • 29
  • 1
  • 5
  • Facebook doesn’t allow you to upload animated GIFs. – CBroe Feb 18 '15 at 22:01
  • It's possible. I can post gif if I set "href": "http://i.imgur.com/D8cdFqP.gif". But if I click on post from facebook I go to http://i.imgur.com/D8cdFqP.gif. But I want go to http://i.imgur.com/D8cdFqP. If I set "href": "http://i.imgur.com/D8cdFqP" I get just article post without animated gif. Imgur and giphy handle it somehow. I mean they post "http://i.imgur.com/D8cdFqP.gif" but redirect to "http://i.imgur.com/D8cdFqP" – im7mortal May 17 '16 at 23:57

2 Answers2

0

You have to share the link to the GIF it self:

FB.ui({ method:'share', href:'http://i.giphy.com/Kr4qE2Lm769HO.gif'});

Try to share this url http://i.giphy.com/Kr4qE2Lm769HO.gif in your fb timeline and you will see how it works.

villeiv
  • 1
  • 2
  • i am trying to upload gif files from my blog to my facebook page. if i try to copy/paste your gif url, the gif can be playeble. what is special about giphy.com? when i try to share "http://bestgifever.com/data/images/2015/11/a355d1b5f5018b686c4a3cd637061ec0.gif" this url can not be playable at facebook. i don't get it. – fozuse Nov 06 '15 at 15:55
  • Your URL has a double quote at the end. if you delete it, you would have no problems, I just try it. – villeiv Nov 24 '15 at 21:54
0

I am using PHP videos for GIF and it's working perfect

$linkData = [
    'message' => $gifyTitle,
    'source' => $fb->fileToUpload($fileName)
];      
$response = $fb->post('/me/videos', $linkData,$pageAccessToken);
clemens
  • 16,716
  • 11
  • 50
  • 65