This thread is resolved. Here is a description of the problem and solution.
Problem: You are trying to export a site configured with ACF fields into XLIFF and encounter an 'ERROR OCCURRED' message without additional information. You suspect incorrect settings on your localhost. Solution: The error may be due to spaces at the beginning of the theme files, which can obstruct output and print logs, leading to errors. We recommend disabling debug mode to resolve this issue. Additionally, ensure your language codes are correctly configured by checking the following documentation on language codes: https://wpml.org/forums/topic/show-country-code-in-language-switcher/
If this solution does not apply to your case, or if it seems outdated, we highly recommend opening a new support ticket. Also, please check related known issues at https://wpml.org/known-issues/, verify the version of the permanent fix, and confirm that you have installed the latest versions of themes and plugins. For further assistance, you can contact us directly through our 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.
Background of the issue:
I want to export a site configured with ACF fields into XLIFF. I am working on localhost and suspect I have incorrect settings.
Symptoms:
I receive an 'ERROR OCCURRED' message without any additional information.
Questions:
How do I correctly configure ACF fields for XLIFF export?
What settings might be causing the error during XLIFF export?
Hi, I have the website online now. I tried to export the xliff and it does not work still.
Which info would you need from my side? I have a custom theme and I use ACF.
To debug this issue further, I would need to check your site settings once, for this I would need temporary access (wp-admin and ftp) to your site.
So could you please provide me with those details, you will find the needed fields for this below the comment area when you log in to leave your next reply. hidden link
The ftp details is not working for me, can you check? I have enabled the private reply again.
Also, It looks like there is some php error happening on your site which is creating the problem, being so can you please follow the below steps and share me the results.
Can you instead provide me wp-content and database backup of your site, you can zip those files and share the links with me. This way I will replicate your site on my localhost for further debugging.
Due to this there is no content for translations only titles, if I remove the code and resend for translations I can download the xliff file, can you please check it on your end and see if it helps.
Hi, I activated gutenberg for pages to test it, but it did not work for me. Same error.
Btw: I do not want to activate Gutenberg, it should be deactivated. Can I export XLIFF anyways? It should extract all the strings from ACF.
Also your theme index.php file is not correct plus, few theme files has spaces in the beginning, like functions.php, please check and correct them accordingly and see if it helps.
it worked after your setup in my wp-config.php. Please do not install any additional plugins in my wordpress, like the data manger, I do not want that.
Index.php is fixed now, but I do not need it... and as I mentioned, the theme is in development. Is WPML sensitive to things like that?
I have another question: Is there an option to set the language display to shortcuts like, DE, EN, FR etc?
I deactivated Gutenberg again and it woks fine. I can download XLIFF now. So what was the issue here?
The issue was happening due to spaces at the beginning of the themes files, this was obstructing the output and printing the logs resulting in the error. Disabling the debug helped in that manner.
Hi,
This is very insightful, thank you so much! I will remember this: no spaces in php files at the beginning. I also managed to set the language switcher as I wish :). I think we can close this thread for now. I will implement the translations soon, I hope everything will be smooth.