 simonM-37
|
HI Carlos
The process completed (see screenshot), but no joy. It is still rejected the coupon.
Kind regards
Simon
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Hi Simon,
Please follow these steps and let me know the results:
- Edit the page in the original language
- Switch to the secondary language using the language switcher that appears in the admin bar (top)
- Click on the option to 'edit anyway' that will appear in a pop-up window
- Set the correct URL for the first button
- Save the changes
- Check if the issue disappears for that button in the frontend in the secondary language
Can you tell me the results of the steps described above?
|
 simonM-37
|
HI Carlos
That workaround works, and the correct add-to-cart URL is used in German for all buttons (I changed all of them).
For the mobile version, the HTML version already contained the correct versions.
However this is only a workaround, since if I make further edits to those translations in the future using the standard translation procedure (see screenshots from WPML/Elementor), the German edits which were saved will be lost again. WPML should be able to translate these URLs automatically or at least present them in the translation screen for manually entry/translation.
The two checkout/coupon screenshots are once from adding the product with the mobile version of the site, and once from a desktop browser.
Kind regards
Simon
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Hi Simon,
Please check now: hidden link
|
 simonM-37
|
Hi Carlos
What exactly, should I be checking for? I don't see any difference and the URLs are still not presented for translation for non-mobile versions (those coming from the Elementor Price Table widget) ...
Kind regards
Simon
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Hi Simon,
Now you can see and translate the URLs when translating the page.
Please edit the page in the original language -> Add a slash and the end or remove the last slash of the URLs in the buttons -> Save the changes and update the translation. Now you should see the option to translate the URLs.
|
 simonM-37
|
Hi Carlos
OK, now I can see the URLs available to translate as expected ... but how did you get that to appear? By adding or removing a slash at the end of the URL?
What is the "correct" (or expected) definition of the URL? With of without a slash at the end?
Because I will have to fix this on our production site too...
Kind regards
Simon
|
 simonM-37
|
Hi Carlos
I tried the following on Production:
1) Edited the button and added and removed the slashes.
2) Published in Elementor.
3) Tried to translate it: no changes, no URLs presented to translate.
Then I tried:
4) Edited buttons and added a slash on all of them. Then published.
5) Then edited the buttons again and removed all the slashes and re-published.
6) Tried to translate it: no changes, no URLs presented to translate.
I cannot seem to "force" an update on Production to make WPML realise there was some change... All of these "workarounds" still seem a bit clunky to me. It still feels like I'm trying to "trick" WPML into doing something it should be capable of already.
Kind regards
Simon
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Hi Simon,
1.- I registered the price table element by following the steps described in this guide: https://wpml.org/documentation/support/multilingual-tools/registering-custom-elementor-widgets-for-translation/ and you can find the code in WPML -> Settings -> Custom XML Configuration tab. By registering the element, I added the URL so WPML 'knows' there is a URL in the element.
2.- The URL can have a slash or not at the end, that makes no difference at all, however, adding/removing the last slash and then re-saving the page forces the WordPress core to refresh the entry in the database for that page which let WPML knows there is a change and allows it to 'pick up' the URL fields already defined in the previous step.
To solve the problem in the production site you must copy/paste the XML code from the dev site in WPML -> Settings -> Custom XML Configuration tab to the same place in the production site. Then edit the page, edit the URLs (add/remove the last slash), save the changes and update the translation.
|
 simonM-37
|
Hi Carlos
Firstly, this works for the moment in production (thank you!) and the coupon can be applied successfully in German.
However, I don't feel this is acceptable as the permanent solution as I am just using a standard, well-established Elementor Pro widget, which has been in the plugin for years, not a custom widget, and have never had to go through this procedure (https://wpml.org/documentation/support/multilingual-tools/registering-custom-elementor-widgets-for-translation/) to translate other standard Elementor widgets.
Has something changed with the WPML Plugin to make this procedure become necessary? It should not be necessary for standard Elementor or Elementor Pro widgets in my opinion.
Furthermore, the Custom XML provided, while it works, is only masking the core bug in WPML which is preventing it from not making the URLs visible using standard translation procedures.
Can you please give me an idea of when is WPML planning to fix this issue permanently so i can remove the custom XML from our website?
Kind regards
Simon
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Hi Simon,
The Elementor shortcodes register by WPML are listed here: hidden link and the 'price-table' element is not listed. That is the reason why I had to register the element on your site.
I'd recommend that you contact the Elementor support service and ask them to create the wpml-config.xml file to register all the elements missing.
|
 simonM-37
|
Hi Carlos
Hmm, OK.
Just to know for future reference then: did you download that Multilingual Tool as a plugin and then delete the plugin on our dev site? I don't see that plugin listed in our list of installed plugins?
Kind regards
Simon
|
 simonM-37
|
Correction: I see the plugin now as "Mutlilingual Tools", I was looking for WPML something...
Can the plugin be deleted now?
Kind regards
Simon
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Hi Simon,
The Multilingual Tools plugin is still installed in hidden link and you can download it from this page: https://wpml.org/documentation/support/multilingual-tools/
|
 Carlos Rojas
WPML Supporter since 03/2017
Languages:
English (English )
Spanish (Español )
Timezone:
Europe/Madrid (GMT+01:00)
|
Yes, you can delete the plugin now.
|