Viewing 22 posts - 1 through 22 (of 22 total)
  • Author
    Posts
  • #1440542

    Hello everyone
    I have created various portfolio pages here: 1 link below:
    these are sorted by title.
    when i open a portfolio: 2 Link below:

    I can scroll sideways.
    however, this scrolling is not done by title but by the order in which they were entered.
    is it possible to set the scrolling by title?

    thanks
    kind regards
    Franz

    #1440906

    Hey schweg33,

    Thank you for the inquiry.

    You can add this filter in the functions.php file to sort the items by title:

    function avf_get_prev_post_sort_mod( $sort ) {
    	return "ORDER BY p.post_title DESC LIMIT 1";
    }
    add_filter( 'get_previous_post_sort', 'avf_get_prev_post_sort_mod' );
    
    function avf_get_next_post_sort_mod( $sort ) {
    	return "ORDER BY p.post_title DESC LIMIT 1";
    }
    add_filter( 'get_next_post_sort', 'avf_get_next_post_sort_mod' );
    

    Best regards,
    Ismael

    #1440914

    Hello Ismael
    Thank you for your answer
    if I insert this into the function php it does not work.
    Maybe this is because I already have an entry.

    /*archive village history filter portfolio by individual categories*/
    function enfold_customization_postnav($settings){
    $settings[‘is_fullwidth’] = false;
    $settings[‘skip_output’] = false;
    $settings[‘same_category’] = true;
    return $settings;
    }

    Could you insert sort by title here?

    Thank you
    kind regards
    Franz

    #1440929

    Hi,

    Thank you for the update.

    We may need to access the site and test the modification further. Please provide the login details in the private field and make sure that the Appearance > Theme File Editor is accessible.

    Best regards,
    Ismael

    #1440955

    Hello Ismael
    thanks for your answer
    since I am not allowed to pass on the login data from the board of this association, I have made a copy of the page here:

    There are no pictures inside, but I don’t think that has any influence on the browsing of the portfolio.
    for example here: Link below:

    if you click on kulturtag-2019, you should be able to scroll to kulturtag-2022 and then to kulturtag-2023?

    thanks in advance
    kind regards
    Franz

    #1441250

    Hi,

    Thank you for the info.

    We’ve tested the modifications for a while, and the filters seem to be correct based on the documentation. However, they’re not working as expected for some reason. We’ll keep you updated once we discover the issue.

    Best regards,
    Ismael

    #1441252

    Hi Ismael

    Thank you very much
    I’ll wait and see
    it would be nice if they would work.
    otherwise you are always not sure whether to scroll left or right

    thanks in advance
    kind regards
    Franz

    #1441353

    big problem is – if you have “same category” set via your snippet – and you have portfolios that have more than one cat!

    #1441389

    An Guenni 007
    Thanks, but:
    Because of the categories, the sorting must work in exactly the same way, right?

    #1441393

    Yes – if each post belongs to exactly one category, it should work. But what if the current post belongs to categories A and B – where should it be linked to then?
    Multiple categorisation is not unusual.

    #1441395

    thanks for your info
    but these posts all belong to one category
    and each post is only assigned to one category.
    so I think that should work ?

    #1441399

    it is the structure of your titles – they formed with numbers ( your years ) there are options of natural sort order (SORT_NATURAL) etc.
    the trouble is if you like to sort by titlel and titles are f.e. A1, A2, A10, B1, B20, B3 etc.
    does a sort order could be A1, A10, A2, B1, B3, B20
    i do not know if this has influence on that filter ?

    #1441400

    super thanks
    can i send you the login data by e-mail?

    #1441446

    No – please don’t.
    I only come here occasionally and give my opinion on topics, but I have enough projects of my own at the moment – so I don’t want to take responsibility for other people’s projects.

    for so few posts within a category, I would rather install a plugin that supports a custom post order to quickly find a solution. There you can customize the order of the posts by drag and drop.
    Such a plugin would be, for example, Simple Custom Post Order

    #1441488

    thanks for the tip
    but I have no idea how to install this plugin
    is there a description somewhere

    kind regards

    #1441550

    Hello Ismael
    Is anything else being done by you in this matter.
    It would be important for me. That scrolling by title works.
    I hope to hear something positive from you.

    thanks in advance
    kind regards
    Frant

    #1441596

    hm – on functions-enfold.php line 827 i found the orderby : post_date
    and the filter avf_post_nav_loop_args – but have no success with post_title

    #1441637

    Hello Guenni 007

    This is the complete entry in the function.php
    into category and sort

    Have I done something wrong here?

    Thank you
    kind regards

    #1441659

    No – I only “think” out loud.
    As I understand it, only the order in which they are looped is different – how to solve this?

    #1441791

    Can this be solved at all
    or is there another possibility that the sorting is correct.

    further up Ismael writes:
    “We have tested the changes for a while, and the filters seem to be correct according to the documentation. However, for some reason they are not working as expected. We will keep you updated as soon as we discover the problem*

    I should only have an answer if the problem is solved.
    Otherwise I will have to try to find another display completely.

    thank you kind regards Franz

    #1442324

    Thanks to Guienni007
    and Ismael

    as I have not received a result please close this request
    I have created a submenu with full width.

    this should work for me

    you can close these requests

    kind regards Franz

    #1442327

    Hi,

    Thanks for the update, we’ll close this thread for now then. Please open a new thread if you should have any further questions or problems.

    Best regards,
    Rikard1

Viewing 22 posts - 1 through 22 (of 22 total)
  • The topic ‘scroll left and right for portfoloio title’ is closed to new replies.