-
AuthorPosts
-
February 20, 2015 at 12:34 pm #399571
Hi guys
another problem.
I am using the Post Types Order plugin to order all my portfolio items, but they are showing in reverse order in the portfolio side navigation (or whatever that is called). See this page http://test.theunsteadyproblem.com/2015-program/ and click on the first film 24 Jours and you will see it is running backwards. I have used this plugin with enfold with no problems before. Can you see what the problem is? thanks!
NancyFebruary 20, 2015 at 12:36 pm #399573Hi!
Have you tried adding the code posted here – http://kriesi.at/documentation/enfold/how-to-add-an-orderorderby-option-to-the-blogpost-sliderportfoliomasonry-grid-element/ and tried ordering posts manually Nancy?
Best regards,
YigitFebruary 20, 2015 at 12:39 pm #399576I have not tried that but was just looking at it. Is the post types order plugin not compatible with the new update? I kind of like being able to sort it manually, since on some sites I need to sort them in groups in a particular order. Does that code let me do that? I hate to think that the big sit I built last year will have issues due to this – it’s not so crucial on this site.
thanks- This reply was modified 9 years, 9 months ago by Munford.
February 20, 2015 at 1:00 pm #399587OK I put in that code and disabled the post order plugin, but I am not getting the right results. I have set the custom query to “ascending order” but the portofolio items are not sorting that way when you go to the individual items (they are in the order shown in the portfolio list) When I used the plugin they were in order by title but reversed. ????
February 21, 2015 at 11:38 am #400032Hey!
Did you set the Custom Query Orderby option to “Title”? Default is by date.
Cheers!
IsmaelFebruary 21, 2015 at 12:11 pm #400046here are the settings I am using:
- This reply was modified 9 years, 9 months ago by Munford.
February 22, 2015 at 8:36 pm #400260This reply has been marked as private.February 23, 2015 at 11:42 am #400533Hey!
We removed the order option then replace it with this:
add_filter( 'avia_post_grid_query', 'custom_post_grid_query', 10, 2); function custom_post_grid_query( $query, $params ) { $query['orderby'] = 'title'; $query['order'] = 'DESC'; return $query; }
The portfolio is now sort by title in descending order.
Regards,
IsmaelFebruary 23, 2015 at 12:06 pm #400551thanks for taking a look. But I don’t see the portfolio items being in order in the side navigation, and now the portfolio grid is sorting in reverse order even though it is set to “Ascending”?? Before, the portfolio grid was sorting correctly with the settings I had (“title” > “ascending”) but the side navigation (when you are on one of he portfolio item pages) was not ordering (still displaying in the order they are in under portfolios) ?? PLease help!
Also-
Do you have any idea why the site is suddenly displaying at 1010px width now? I have it set to 1310…?- This reply was modified 9 years, 9 months ago by Munford.
February 23, 2015 at 12:23 pm #400572Hey Nancy!
Wanted to check the width issue but login credentials are not working. Can you please check them once again?
Best regards,
YigitFebruary 23, 2015 at 12:27 pm #400577This reply has been marked as private.February 23, 2015 at 12:34 pm #400584I changed the code in my functions.php that you added to:
$query[‘order’] = ‘ASC’;which fixed the order in the grid but the side navigation for the portfolios is still not sorting.
- This reply was modified 9 years, 9 months ago by Munford.
February 24, 2015 at 9:48 am #401232Hey!
Glad you figured that out If you want to reverse the post navigation order, add this to the functions.php file:
add_filter('avia_post_nav_entries', 'avia_apply_custom_sort_order_to_post_nav', 10, 2); function avia_apply_custom_sort_order_to_post_nav($entries, $settings) { $temp_prev = $entries['next']; $temp_next = $entries['prev']; $entries['prev'] = $entries['next'] = ""; if(!empty($temp_prev)) $entries['next'] = $temp_prev; if(!empty($temp_next)) $entries['prev'] = $temp_next; return $entries; }
Best regards,
IsmaelFebruary 24, 2015 at 10:35 am #401264But I dont’ need that earlier code you added – since the portfolios in the grid were sorting correctly using the “order by” and “display order” settings. I am only needing something that works like the “post types order” plugin. I will try your recent code and see if it works.
thanks
NancyFebruary 24, 2015 at 10:39 am #401268hmm that doesn’t seem to be working – see on the test site here:
http://test.theunsteadyproblem.com/2015-program/
still using these settings:
the grid is fine, but the navigation is still not sorting from the individual pages.
any suggestions?
NFebruary 25, 2015 at 6:36 am #401862Hi!
The recent code we posted is different from the previous one. Please check. You don’t need to add the order and orderby option. We already fixed that by adding this code:
add_filter( 'avia_post_grid_query', 'custom_post_grid_query', 10, 2); function custom_post_grid_query( $query, $params ) { $query['orderby'] = 'title'; $query['order'] = 'ASC'; return $query; }
Now, if you want to reverse the post nav, use this one:
add_filter('avia_post_nav_entries', 'avia_apply_custom_sort_order_to_post_nav', 10, 2); function avia_apply_custom_sort_order_to_post_nav($entries, $settings) { $temp_prev = $entries['next']; $temp_next = $entries['prev']; $entries['prev'] = $entries['next'] = ""; if(!empty($temp_prev)) $entries['next'] = $temp_prev; if(!empty($temp_next)) $entries['prev'] = $temp_next; return $entries; }
If you’re referring to a different navigation other than avia_post_nav function, please provide a screenshot.
Cheers!
IsmaelMarch 4, 2015 at 6:15 pm #405939Hi guys,
sorry maybe is not the right post, but i need to change the portfolio Masonry order (no the portfolio slide, that i can change inside Enfold Advanced Editor), but i would like to change the “category” order, that i think is setted alphabetically ) Ex. All, Army, Battle, Cat, Dentex, … bla bla
I would lke to change this order, i’m working on artistic portfolio and i need to have latest work on top All / 2015 / 2014 / 2013 / 2012, but i can’t chage this order by backend…and the default order is All / 2012 / 2013 / 2014 / 2015
I link you a slide about my problem, http://www.3mediastudio.com/bozze/sorting_filter_gallery.jpg
Let me know asap, and thank you very much for time, Enfold is the most powerfull theme EVER, there are no comparisons
R.March 5, 2015 at 2:33 pm #406408Hey!
Yes, please create your own thread. We’ll answer you there. Anyway, try to edit config-templatebuilder > avia-shortcodes > portfolio.php. Look for the sort_buttons method. Add the order and orderby parameter to the get_categories function: http://codex.wordpress.org/Function_Reference/get_categories#Parameters
Cheers!
Ismael -
AuthorPosts
- The topic ‘portfolio order reversed?’ is closed to new replies.