Note that there are some explanatory texts on larger screens.

plurals
  1. POfacebook graph api comment list sort , like 'orderby=desc'?
    primarykey
    data
    text
    <p>I use graph api to get the picture's comments, but I want to first sort the results by creating time and then return to the latest data. Similar to the sql statement 'order by create_time desc', I do not know if have such a parameter.</p> <p>Currently used to offset and limit access to the latest data, but also know the total number of comments,</p> <pre><code>pagesize = 25; offset = comments.count - pagesize; limit = 25; </code></pre> <blockquote> <p>url = "https://graph.facebook.com/" + object_id + "/comments?access_token=" + access_token + "&amp;limit=" + limit + "&amp;offset=" + limit;</p> </blockquote> <p>next page:</p> <pre><code>offset -= 25 </code></pre> <p>but comments.ount of numerical sometimes is not accurate</p> <p>and the result of the request URL to return to sometimes don't match</p> <blockquote> <p>Whether to have very good solution</p> <p>Or I used the wrong way (‘limit’ and ‘offset’ Parameter)!!!</p> </blockquote> <hr> <p>Thank you for your answer.</p> <p>"Graphics API" the existence of the cache?</p> <p>i post a message and 46 comments.requests url, set the parameters: </p> <blockquote> <p>offset=0&amp;limit=1</p> <p>Then it should return to the last comment (latest one), the actual return to the middle of a comment, and I tested a few times, set the offset and limit. According to the returned results, the middle one is the latest comment</p> </blockquote> <p>If I set the limit value is greater than the 'comment.count', the returned data is all, the official website and facebook consistent</p> <p>Because the cache reason?</p> <p>Thanks again~</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload