Tagged: translation
-
AuthorPosts
-
September 16, 2019 at 7:48 pm #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!
September 18, 2019 at 7:08 pm #1139633Hey,
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,
YigitSeptember 20, 2019 at 9:28 pm #1140344Hi 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!
September 20, 2019 at 9:38 pm #1140349Hi 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!
September 21, 2019 at 12:03 am #1140373Hi,
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 -
AuthorPosts
- The topic ‘Translate “ALL” in protfolio filter’ is closed to new replies.