Okay
  Public Ticket #1258728
Portfolio Previous - Next Bug
Closed

Comments

  • Nick started the conversation

    Greetings,

    I have problem with the options previous-next buttons in my portfolio setup.

    I've put my portfolio items in taxonomies but when clicking previous/next instead of showing the correct order of the items, it shows them based on alphabetical order.

    With some research I've made in theme's core files I found on line 3973 of functions.php that the portfolio engine shorts the items via post date.

    $sort = apply_filters( "get_{$adjacent}_post_sort", "ORDER BY p.post_date $order LIMIT 1" );


    Although it's not working like it says and shorts them in alphabetical order.

    Looking forward for your reply because I need to fix that for my client.


  •  9,013
    Tahir replied

    Hey Nick,

    See screenshot : http://prntscr.com/g2g43v . You need to adjust the project_single_controls function in functions.php file .

    Be.st 


    ThemeNectar Support Team 

  • Nick replied

    I've changed  'orderby'         => 'menu_order title', to   'orderby'         => 'post_date', and it worked. of the function project_single_controls()

    Though in order to work properly on my child theme since i've copy the whole function in it , it needed to include the function project_single_controls() in the funtion.php of parent theme inside if (!function_exists('project_single_controls')) {}


    How I can disable the parent theme function so in case of an update the change i made and put inside functions.php of child theme will work ? 

  •  9,013
    Tahir replied

    Hey Again,

    At the moment the function is not compatible with a child theme . Though have noted to have this in upcoming updates. 

    Be.st 


    ThemeNectar Support Team