Tagged: , ,

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #25488

    I’ve created a portfolio page that pulls in galleries created in portfolio pages. I want them to show up with the most recently created portfolio/gallery to be in the first position. I’ve checked other support questions and found this code (below) and pasted it at the end of the functions.php file, but didn’t work. I also changed ASC to DESC. Here’s the page it’s on where India photos should be first: http://withthisring.org/check-us-out/gallery/

    Please advise:

    function loop_portfolio_query( $location )

    {

    if ( $location == ‘loop-portfolio’ )

    {

    global $avia_config;

    if(isset($avia_config)) {

    $avia_config = “date”;

    $avia_config = “DESC”;

    query_posts($avia_config);

    }

    }

    }

    add_action( ‘avia_action_query_check’ , ‘loop_portfolio_query’, 10, 1 );

    Thanks for your help!

    #127161

    Hi,

    You can use this plugin:

    http://wordpress.org/plugins/post-types-order/

    Regards,

    Ismael

Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘Sort Portfolio by Date’ is closed to new replies.