This thread is resolved. Here is a description of the problem and solution.
Problem: The client is trying to make Search & Filter Pro work with a second language on their website. The filters should capture values from an ACF field, which are translated using WPML String Translation. However, the filters do not recognize the translated values.
Solution: We have investigated the issue and our 2nd Tier Support has provided feedback. The problem arises because while labels can be translated using ACFML filters when calling ACF functions on the front end, the translated values, which are part of post meta, cannot be translated on the front end. Manually adding translated values in the code of the Search and Filter Pro plugin is not recommended, as these values may change upon post translation, leading to mismatches.
We recommend keeping the values common across all languages and translating only the labels. You can set up your ACF fields with a value:label pair and then translate the labels, keeping the values the same. For example:
all : 전체<br />domestic : 국내<br />intl : 국외
This approach ensures that the values remain consistent while the labels are displayed in the correct language to the user.
Please note that this solution might be irrelevant if it's outdated or not applicable to your case. We highly recommend checking the related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If the issue persists, please open a new support ticket with us.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
I've activated Elementor Pro and installed Advanced Custom Fields Multilingual. I've also installed search and filter and I don't think we need a license key for it to work. Could you please replicate the issue now on the sandbox site so that I could check?
I replicated a couple of posts for the custom post type "insight". I imported the CPT, ACF and Elementor template, and replicated the "search & filter" for "insight". I replicated the translation configurations as well.
Search Filter works in both languages, but the translations for ACF select fields are not recognized for both the loop grid and the search filter. It seems like the issue is replicated in the sandbox. Please check out the link below:
hidden link
However, the translations for the ACF select fields are recognized in each individual post. Please check out the link below:
hidden link
So, I thought it may have something to do with compatibility between "search & filter" and "wpml". However, in another post of another post type, translations for ACF select fields are not recognized even within the post. Please check out the link below:
hidden link
I did not replicated this post in the sandbox, as it is not related to "search & filter", but I would like to bring your attention to inconsistency in recognizing translations of ACF select fields.
Let me know if you need additional work from my end.
I am tried a couple of things at my website regarding the issue, and would like to share the outcome with you so that there is no missing points for both of us:
1) Changed the translation option for ACF select fields from "copy once" to "translate";
2) Translated labels for choices at each post through WPML Translation Editor;
As a result:
1) Now, the translations for ACF select fields are recognized, both in the list and in the post (Please check hidden link);
2) However, "search & filter" does not recognize the translations (Please check hidden link);
In this case, the issue becomes the compatibility between "wpml" and "search & filter". I chose "search & filter pro" as its price was reasonable and it was presented compatible with wpml. Hope we can find a solution for this soon.
I have feedback and this is what our 2nd Tier Support mentioned.
The issue is now, that the translated value 국외1 > overseas1 saved to post but Search and Filter Pro is not pulling the translated values in the drop-down on the front-end. And it is expected, why?
Labels are part of the package and ACFML may have a filter to translate them when calling ACF functions on the front end.
Translated values are part of post meta, it is not possible to translate them on the front end.
If we manually put the translated value on the front-end (in the code of the Search and filter plugin) then it can work but this is not recommended as the value can be changed anytime when translating the post and the hardcoded values in the code will not match.
I would suggest keeping the values common in both languages and translating the labels. They can put values: label in ACF and then translate the labels only keep the value same. e.g.
It works great! I completely understand how challenging it is to stay compatible with thousands of plugins in wordpress ecosystem. I think your solution got me what I needed.