Hey guys,
just a small thing in an amazing theme: Is there a way to manually sort the categories in the filterable portfolios instead of having it sorted by the name?
Thanks in advance!
Simon
Hey guys,
just a small thing in an amazing theme: Is there a way to manually sort the categories in the filterable portfolios instead of having it sorted by the name?
Thanks in advance!
Simon
Hi,
Open includes > helper-template-logic.php, find this code
$avia_config['new_query'] = array( 'orderby' => 'ID',
'order' => 'ASC',
'paged' => get_query_var( 'paged' ),
'posts_per_page' => $itemcount,
'tax_query' => array( array( 'taxonomy' => 'portfolio_entries',
'field' => 'id',
'terms' => $terms,
'operator' => 'IN')));
Replace it with
$avia_config['new_query'] = array( 'orderby' => 'ID',
'orderby' => 'date',
'order' => 'ASC',
'paged' => get_query_var( 'paged' ),
'posts_per_page' => $itemcount,
'tax_query' => array( array( 'taxonomy' => 'portfolio_entries',
'field' => 'id',
'terms' => $terms,
'operator' => 'IN')));
You can change orderby & order parameters. This link might help. http://codex.wordpress.org/Class_Reference/WP_Query#Order_.26_Orderby_Parameters
Regards,
Ismael
Ok, I think I was a bit unclear here. I need to manually order the sub-menu that allows me to filter the different categories in the filterable portfolio instead of by the name (and not the posts itself).
Maybe you have an easy tweak for that as well? :-)
Thanks!
I found the fix for that with the plugin 'Category Order and Taxonomy Terms Order'. Does the trick with ease...
Hey,
My bad. I thought you are talking about sorting the portfolio items. Glad you fixed it. :)
Regards,
Ismael
This topic has been closed to new replies.