WordPress.org

Ready to get started?Download WordPress

Forums

WP Facebook Like Posts Order
WP Facebook Like Posts Order - orders alphabetically, not numerically (2 posts)

  1. kateM82
    Member
    Posted 2 years ago #

    I have this installed, and it looks like it is working, however there is one huge flaw.
    The actual sort order is incorrect.
    This plugin will place something with 27 likes as having less likes than something with 3. And if you get something with 9 likes, that goes straight to the top, even if there are many things with more.

    An example of the order it puts " likes" in is below.

    1
    109
    12
    16
    2
    28
    3
    4
    56
    8
    9

    Do you see what I mean (it's more an alphabetical order, than a numerical one)

    This needs to be fixed asap of basically the plugin is useless. if anyone knows hows to fix it, or if the author can please have a look (I have emailed you twice in the last few months and no response) that would be great.

    http://wordpress.org/extend/plugins/wp-facebook-like-posts-order/

  2. jno123
    Member
    Posted 1 year ago #

    Try to use something like:

    global $query_string;
    query_posts($query_string . '&meta_key=facebook_likes&orderby=meta_value_num');

    The goal is to use 'meta_value_num' - Order by numeric meta value

    http://codex.wordpress.org/Function_Reference/WP_Query#Order_.26_Orderby_Parameters

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic