I tried to post messages automatically on my facebook page. It works great, but I want to use a larger image for general publication.
http://cdn.tips4php.net/wp-content/uploads/2010/12/final_post.jpg
I used the following code to post it:
try {
$page_info = $facebook->api("/$pageId?fields=access_token");
$attachment = array(
'access_token' => $MYACCESTOKEN,
'message' => $msg,
'name' => $title,
'link' => $uri,
'description' => $desc,
'picture'=>$pic,
'actions' => json_encode(array('name' => $action_name,'link' => $action_link))
);
$status = $facebook->api("/$pageId/feed", "post", $attachment);
} catch (FacebookApiException $e) {
error_log($e);
$user = null;
}
How can I use a large picture for this post? I saw some general posts from other facebook pages and they have a big photo. Waiting for your reply.
source
share