[Plugin: Posts 2 Posts] Controling the display order of connections

My question resembles one I asked before:

[Plugin: Posts 2 Posts] Changing display order of connections

Read More

But now I want to display the connection in the SAME order I created them ! That is, if I attache quote#1 THEN quote#2 to an article, I want quote#1 to appear before quote#2 regardless of the creation date of these quotes, their alphabetical order or whatever. Don’t know if I make myself clear o_O

Related posts

Leave a Reply

1 comment

  1. With the development version of the plugin (0.8-alpha), you have a ‘p2p_orderby’ query var, which you can use with WP_Query, like so:

    $my_query = new WP_Query( array(
      'connected_to' => get_queried_object_id(),
      'p2p_orderby' => 'my_connection_field'
    ) );
    

    More info on connection fields:

    https://github.com/scribu/wp-posts-to-posts/wiki/Connection-information

    Note that this is alpha software and you still have some work to do on your own.