This thread is resolved. Here is a description of the problem and solution.
Problem:
You are trying to translate a static .twig file in your theme using WPML, but the homepage isn't translating while other pages do.
Solution:
First, ensure that you enable the option to scan these strings. You can register the twig strings using the
getText()
function, prepared as shown below:
{{ __(\'Example heading to translate\', \'example-domain\') }}
Additionally, in the latest version of WPML, you can scan them directly from the WPML Translation Management. There is now a string section available for this purpose. You can learn more about this process in this video: https://wpml.org/documentation/getting-started-guide/string-translation/.
If this solution does not apply to your case, or if it seems outdated, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. Should you need further assistance, please open a new support ticket at WPML support forum.
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.