我正在使用facebook sdk在Facebook墙上分享帖子。我已经成功地在Facebook墙上分享了这个帖子,但现在它的样式可以像?
我尝试发帖如下:
public boolean updateStatus(String accessToken, String message){
String response="";
try {
Bundle bundle = new Bundle();
bundle.putString("message", "Message here");
bundle.putString("description", "description here");
bundle.putString("name", "abc"); //Name of the link
bundle.putString("link", "www.abc.com");
bundle.putString("caption", "link capation");
bundle.putString("picture", "pic url");
bundle.putString(Facebook.TOKEN,accessToken);
response = facebook.request("me/feed",bundle,"POST");
if(response.indexOf("OAuthException") > -1)
{
if(mAuthAttempts==0)
{
mAuthAttempts++;
fbAuthAndPost(message);
}else{
showToast("OAuthException:");
}
}
} catch (MalformedURLException e) {
Log.e("MALFORMED URL",""+e.getMessage());
showToast("MalformedURLException:"+e.getMessage());
} catch (IOException e) {
Log.e("IOEX",""+e.getMessage());
showToast("IOException:"+e.getMessage());
}
}