Jozic
Jozic

Reputation: 19

Wrong picture on FB Wall, feed post from android app (android FB sdk)

I have a problem with Feed post Picture, we decided to change our (android native) FB App icon, so we changed this icon at all occurrences in FB app settings, and we changed the picture on ftp server(on which we refferenced when posting feed from app).

But when I post feed from app (in the feed dialog there is a correct picture), on wall in browser there is wrong(old) picture, weird is when I check my wall from katana(facebook android app), there is a correct picture. Size of picture is 512x512 and it's png format. I'm talking about picture besides the feed (not small icon under feed)

Sample of feed post:

...
Bundle parameters = new Bundle();
parameters.putString("picture", path_tou_our_icon_on_ftp_server_in_png_fromat);
parameters.putString("name", facebookMsgName);
parameters.putString("caption", facebookMsgCaption);
parameters.putString("description", facebook_message);
parameters.putString("link", "http://bit.ly/....");
facebook.dialog(mInstance, "feed", parameters,....

Upvotes: 1

Views: 562

Answers (2)

Yar
Yar

Reputation: 4561

Add "?cache=" + System.currentTimeMillis(); to your image URL posted to FB.

Upvotes: 1

Niraj Shah
Niraj Shah

Reputation: 15457

The reason for this is because facebook are probably caching your image. There are two solutions:

  • Give the new image a different name and update your code to use it. This will force facebook to use the new image, but it means you have to get a update for you app through the App Store, or
  • Wait for Facebook to update it's cache and start using the correct new image.

Upvotes: 0

Related Questions