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


    I’m wondering…

    Is there any option that allow the Portfolio Grid element to choose randomly the Portfolio Item?

    At the moment it is fixed, I’ve tried with sort option but doesn’t work.


    Hey Francesco,

    Thank you for the inquiry.

    You can add this filter in the functions.php file to adjust the query of the portfolio grid element and display the items in random order.

    function avia_post_grid_query_mod($query)
      $query['orderby'] = 'rand';
      return $query;
    add_filter('avia_post_grid_query','avia_post_grid_query_mod', 10, 1);

    Best regards,

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.