Tagged: 

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

    Hello,

    I’m trying to translate the word “ALL” in the portfolio filter. I found the following topics from 2015 but neither solution worked for me (I’m inserting the code in the functions.php file of the child theme). I don’t use any translation plugins, only Multisite. Could you help, please?

    https://kriesi.at/support/topic/translate-the-word-all-in-portfolio/
    https://kriesi.at/support/topic/multisite-changing-avf_portfolio_sort_first_label-different-languages/

    Thank you in advance!

    #1139633

    Hey,

    Please try using the code as following

    add_filter('avf_portfolio_sort_first_label','new_first_label');
    function new_first_label() {
    if (get_locale() == 'en_GB') {
    $first_item_name = "New All Text English";
    }
    if (get_locale() == 'de_DE') {
    $first_item_name = "New All Text German";
    }
    return $first_item_name;
    }

    Best regards,
    Yigit

    #1140344

    Hi Yigit,

    Thank you for your answer.

    Unfortunately it doesn’t work with either language.
    I also tried to set the conditions to check the url with get_site_url(), then to check the page’s title with get_the_title(), without success in either cases…

    I’m sure that I’m putting the code in the right file, because I’ve successfully enabled and disabled the builder debug mode on various locations.

    Do you have any other suggestions?

    Thanks!

    #1140349

    Hi again,

    I found a solution right after posting the above comment:)

    It’s actually an answer from you in another thread on the forum that I’ve somehow missed on my first search:
    https://kriesi.at/support/topic/how-can-i-change-the-word-all-for-the-portfolio-category-filter/

    I replaced ‘avf_portfolio_sort_first_label’ with ‘avf_masonry_sort_first_label’ and it worked.

    Apparently people are having trouble with this occasionally, so why not add it to the documentation at some point:)

    Anyway, thanks again and have a nice week-end!

    #1140373

    Hi,

    I’m glad this was resolved for you. If you need additional help, please let us know here in the forums.

    Best regards,
    Jordan Shannon

Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘Translate “ALL” in protfolio filter’ is closed to new replies.