Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #642672

    Kriesi Team,
    Thank you for your fine work that makes us look good!

    Using your instruction – on the Magazine element:

    I found the sort to work well for “ALL ITEMS” (todos in Spanish). However, when switching to the tab view (example himnos) the sort is lost. How might I add the same sort to all views no matter which tab is displaying?

    Example (URL in Private Content)

    #643243

    Hey Julie!

    Thank you for using Enfold.

    Please remove the modification or the extra options then use this in the functions.php file:

    add_filter('avf_magazine_entries_query','avf_magazine_entries_query_mod', 10, 2);
    function avf_magazine_entries_query_mod($query, $params) {
    	$query['orderby'] = 'title';
    	$query['order'] = 'ASC';
    	return $query;
    }
    

    Cheers!
    Ismael

    #643457

    Hi Ismael,
    Thanks for the response. However, I get an error now.
    Parse error: syntax error, unexpected 'function' (T_FUNCTION) in /nas/content/staging/ilcristo/wp-content/themes/enfold-child/functions.php on line 3

    The site doesn’t display because of this.

    #643459

    Ah ha! I figured it out on my own :) The single quotes translated to entities when copying and pasting the code. Replacing those gave me good results. Thank you so much for this solution.

    Magazine posts are now sorted by title in ascending order no matter which filter is chosen. Yes!

    #643788

    Hi,

    Great, glad you got it working. Please let us know if you should need any more help on the topic.

    Best regards,
    Rikard

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