I would like to get post_ids of user's posts using FQL query.
I have used such a code:
<?php
$fql_query = "SELECT post_id FROM stream WHERE (post_id IN ($posts))";
//I have some particular post_ids in $post. I test whether these posts still exists.
$result = $facebook->api(array(
'method' => 'fql.query',
'query' => $fql_query,
)
);
?>
But this code works for me only when the visitor of my website is currently logged in on facebook. I would need to get user's posts (post_id) also when FB user is offline. IS it possible using PHP SDK and FQL, when I have stored user's FB uid and access token in my database?
I am aware, that I need long access token. Should I request it although I have created app on July 2013, so I don't have such deprecated stuff like "offline_access". How will I use the access token, so I will have permission to request user's posts using FQL query?
I am using Facebook PHP SDK (v.3.2.2
EDIT: I have already find solution in another thread: How do i use FQL with php api? and access token creating URL with FQL query, adding access token as argument