 francoisV-9
|
Hi,
Now it's ok and all the plugins have been updated.
You can thus go on with your tests.
Thank you very much.
|
 Andreas W.
WPML Supporter since 12/2018
Languages:
English (English )
Spanish (Español )
German (Deutsch )
Timezone:
America/Lima (GMT-05:00)
|
The error I mentioned earlier will only affect your site if you use the Advanced Translation Editor to create translations.
Now, on your site, I see the Classic Translation Editor is set as the default translation editor. In this case, you will not run into the earlier-mentioned error.
This time it is a different error that appears to occur when trying to save translations inside the Classic Translation Editor, and this is the case not only for the product, it also happens on posts or pages.
I can confirm the same issue on my test site.
As a workaround for the issue:
Inside the file wc-myparcel-belgium/wc-myparcel-belgium/includes/class-wcmpbe-postcode-fields.php, inside the function getPostedValues() which is located near the end of the file, change the line:
_ajax_wp_die_handler('Invalid nonce.');
into:
// _ajax_wp_die_handler('Invalid nonce.');
or as alternative, replace the line with:
if (!is_admin()) {
wp_die(__('Invalid nonce.', 'woocommerce-myparcelbe'), 403);
}
This will solve the issue, and WPML will be able to create the translation.
Finally, integrating this change would be the task for the author of the plugin, which is why I suggest you report my findings and then follow up with the author from there.
|
 francoisV-9
|
Hi,
Thank you very much for the tests and for the workaround.
When you say "As a workaround for the issue, inside the function getPostedValues() which is located near the end of the file, change the line", which "file" are you talking about exactly?
Are you talking about a file inside the WC MyParcel Belgium plugin?
I will forward your findings and workaround to the MyParcel team so that they can release a new version of the plugin (because I am not a developer and I am unable to implement your change).
Do I need to say anything else to MyParcel?
And about the other issue/error you mentioned earlier (when you use the Advanced Translation Editor), is it also due to the WC MyParcel Belgium plugin?
If yes, how to solve this error and what should I say about it to MyParcel (please tell me exactly what I have to tell them because I am not a developer).
Thank you very much in advance for your help.
|
 Andreas W.
WPML Supporter since 12/2018
Languages:
English (English )
Spanish (Español )
German (Deutsch )
Timezone:
America/Lima (GMT-05:00)
|
My apologies, I have adjusted my comment now.
The code change will need to be made by the MyParcels Belgium Plugin Author, and I would like to ask you to report my findings there.
If the author would like to consult our compatilbity team, he can fill out the following form:
https://wpml.org/documentation/support/go-global-program/
----
The other issues about the Translation Tools tab can currently not be replicated on my test site:
Login:
hidden link
I am not sure what was causing this issue, but it does currently also not occur on your staging site anymore.
|
 francoisV-9
|
Hi,
I forwarded your findings to the plugin author.
Concerning the other issues about the Translation Tools, could you please try to re-activate all plugins and see if the issue occurs again? And if yes, could you please try to check which plugin causes this error (is it still the WC MyParcel Belgium plugin maybe)?
Please de-activate all the plugins except WooCommerce and WooCommerce Stripe Payment gateway after your tests.
Thank you very much in advance for your help.
|
 Andreas W.
WPML Supporter since 12/2018
Languages:
English (English )
Spanish (Español )
German (Deutsch )
Timezone:
America/Lima (GMT-05:00)
|
It seems to be working now.
If this issue with the Translation Tools tab occurs again, please let us know.
|
 francoisV-9
|
Hi,
The WC MyParcel Belgium development team worked on a new version with a fix.
You can download it here: hidden link
Could you please install this version on my staging website and let me know if it resolves the issue?
Then, if it's ok, I will tell it to the WC MyParcel Belgium development team and they’ll release the update via the official WordPress catalogue.
Thank you very much in advance for your tests and feedback.
|
 Andreas W.
WPML Supporter since 12/2018
Languages:
English (English )
Spanish (Español )
German (Deutsch )
Timezone:
America/Lima (GMT-05:00)
|
Now, this was quick 🙂
I installed this version and created two translations of the post "WPML Test" successfully.
I would further suggest that you enable a WPML language switcher:
https://wpml.org/documentation/getting-started-guide/language-setup/language-switcher-options/
Let me know if you have any further questions.
---
Apart from that, take note that there is the following issue that should be reported to WP Rocket.
Is is about their addon "Heartbeat Control by WP Rocket" and relates to the way the addon is loading the text domains for WordPress. This is not an WPML issue but can affect the WPML String Translation.
The author needs to adjust the way in which the text domain is loaded for this addon.
PHP Notice: Function _load_textdomain_just_in_time was called <strong>incorrectly</strong>. Translation loading for the [php]heartbeat-control
domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the
action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/customer/www/staging27.matcha-iro.com/public_html/wp-includes/functions.php on line 6121
[/php]
|