Search code examples
facebooksortingpluginsfacebook-fql

Setting Facebook comments web plugin


The default sorting order of the facebook comments plugin is by social status. How do I set the default order to reverse chronological on my web page?

I know there is an option on the top of the plugin. But not all users know about it and the sorting order is confusing.


Solution

  • Just guessing I added

     data-order-by="reverse_time"
    

    to the div provided by Facebook and it worked nicely. So, loading the pluging with the standard html5 code provided here: https://developers.facebook.com/docs/reference/plugins/comments/

    just add the data-order-by attribute like this:

    <div class="fb-comments" data-href="YOUR_URL" data-width="470" data-num-posts="6" data-order-by="reverse_time"></div>