Reputation: 38492
What works fine for posting to a /feed does not work the same for posting to /links. While no error is generated, and I get an ID back indicating success, the thumbnail I specified as "picture=http://site/url/photo.gif" does not show up. Here is the command I used:
curl -F \
"picture=http://tycho.usno.navy.mil/gif/moons/m146.gif" \
-F "message=How I look tonight to my worshippers on Earth" \
-F "name=Current Moon Phase" \
-F "link=http://www.calculatorcat.com/moon_phases/phasenow.php" -F caption="How the Moon appears tonight" \
-F "access_token=111111111111111|2222222222222222222222222|33333333333333333333456n" \
"https://graph.facebook.com/215958041750734/links"
Now, the same data, but published to The Moon's wall (feed), works as expected:
curl -F \
"picture=http://tycho.usno.navy.mil/gif/moons/m146.gif" \
-F "message=you're looking great tonight!" \
-F "name=Current Moon Phase" \
-F "link=http://www.calculatorcat.com/moon_phases/phasenow.php" -F caption="How the moon appears tonight" \
-F "access_token=111111111111111|2222222222222222222222222|33333333333333333333456n" \
"https://graph.facebook.com/215958041750734/feed"
The results of both can be seen in the June 13 posts on the Facebook "The Moon" page: https://www.facebook.com/pages/The-Moon/215958041750734
Any way to get the thumbnail picture to show up on The Moon's own post to /links?
Upvotes: 2
Views: 2366
Reputation: 1114
I also found Facebook not accepting my images (I am using their Javascript SDK), but your image was fine. It worked for me to just not include the image with the call, making Facebook figure the image out by itself. I did not particularly care what the image will be, just needed any.
Upvotes: 0
Reputation: 38492
From experimentation, it turns out that the "picture=" option, if present, is ignored. It pulls a thumbnail from the page itself, if any images happen to be on it; otherwise no thumbnail can be displayed. As a workaround, one could embed the desired content on a server under his own control, in a frameset or iframe, and embed the desired thumbnail in that page, posting that link to the desired facebook id's /links object.
Upvotes: 3