Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problema:
El cliente tiene problemas con un plugin de eventos que no refleja los cambios de tickets y pagos en las versiones traducidas del sitio. Además, el cliente ha añadido manualmente un widget de pago, pero no aparece en el sitio traducido.

Solución:
1. Hemos identificado el problema y aplicado una solución mediante código en el archivo

functions.php

del sitio del cliente:

/**
 * Translate page ID for WPML.
 * 
 * @link wpmlsupp-11347
 * @param mixed $page_id 
 * @return mixed 
 */
function wpmlsupp_11347_translate_page_id( $page_id ) {
	return apply_filters( 'wpml_object_id', $page_id, 'page', true );
}
add_filter('tec_tickets_commerce_checkout_page_id', 'wpmlsupp_11347_translate_page_id');
add_filter('tec_tickets_commerce_success_page_id', 'wpmlsupp_11347_translate_page_id');

2. Hemos recomendado al cliente que se comunique con los autores del plugin de eventos para informarles sobre la incompatibilidad con WPML.
3. Hemos sugerido la creación de un tema hijo para evitar la pérdida de personalizaciones del tema cuando se actualice. Se proporcionaron instrucciones y recursos para crear un tema hijo, incluyendo un enlace a la documentación oficial de WordPress sobre temas hijos y un video tutorial en YouTube.

Si la solución proporcionada no es relevante para tu caso, porque podría estar desactualizada o no aplicarse a tu situación específica, te recomendamos abrir un nuevo ticket de soporte. También te sugerimos revisar los problemas conocidos, verificar la versión de la solución permanente y confirmar que has instalado las últimas versiones de temas y plugins. Si necesitas más ayuda, no dudes en contactarnos en el foro de soporte de WPML.

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.

Tagged: 

This topic contains 18 replies, has 3 voices.

Last updated by Alejandro 6 months, 1 week ago.

Assisted by: Alejandro.

Author Posts
April 30, 2024 at 6:08 pm #15582430

Fiyinfoluwa Lasaki

After installing WPML I noticed that if my make a website change on the English version, it doesn't reflect on the other language sites and I have to make the same changes there..Currently I have an issue in the sense that, an events plugin I'm using for people to book events, the tickets and payment feature are not made available on the other site languages..I went ahead to add one manually again but the payment widget to input card details isn't coming up for the translated site..here's my site link..wegamed.com

I need assistance asap

April 30, 2024 at 9:45 pm #15582856

Lucas Vidal de Andrade
Supporter

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Thank you for contacting WPML support. While you are waiting for one of my colleagues to take this ticket and work on it, let me provide you with first debugging steps or if I can perhaps help with the issue quickly.

As for your first question, depending on how WPML is set-up, that's expected. When you change a text in the original language, the translations must manually update or sent to automatic translation. How are you translating your pages?

As for the other questions, they require more attention. One of my colleagues will soon come to continue support.

April 30, 2024 at 10:03 pm #15582868

Fiyinfoluwa Lasaki

I had it on manual translation initially, but after I found out about the duplicates not being updated. I changed the settings to automatic translation.

I would appreciate a swifter response on the other issue as it is an urgent one

May 2, 2024 at 2:42 pm #15588072

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Hello there!

If you use "translate everything" mode then, all the changes should happen as soon as you save the changes, the thing is that you mention an events plugin and things might work differently and might require further configuration.

Can you let us know what changes are you talking about and if they come from the events options or any other options on a page, and we're not talking about actual content like text, title or similar?

This will help me understand better the situation so we can proceed to find a solution.

May 2, 2024 at 2:46 pm #15588161

Fiyinfoluwa Lasaki

The changes I'm currently talking about are from the event option, on the translated pages the events ticket and checkout options are not available which is not so for the English site. So people checking the site other languages are unable to make payment and book event.

May 2, 2024 at 3:50 pm #15588446

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Can you write here the steps to see that and configure it on the original language (English) and then, if possible allow me access to your site so i can check it out and try to find any clues. i won't touch anything without your consent 🙂

Regards.

May 3, 2024 at 9:08 am #15590379

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Hello!

Please check this video: hidden link

The main issue here is the current configuration with WPML and a lack of compatibility (or maybe a partial one). unfortunately we've tried to reach them several times about this without any answer from their end 🙁 but they DO mention that the plugin you have is currently NOT compatible with WPML here: hidden link

This is a sort of known issue that has however evolved and the main issue right now is that every ticket added as an event is added as a "ticket commerce ticket" post type. it seems we can't "assign" an already created ticket to an event so that means that we always have to create new ones.

------------

A workaround would be to go to WPML > Settings > Custom post type translation, find "Tickets Commerce Tickets (tec_tc_ticket)" and set it as "not translatable", that way you'll be able to add your tickets manually on each translation without needing to deactivate the translation editor.

I strongly suggest you, as their plugin customer, express your wish of collaboration for this plugin to their support in hopes they will raise the compatibility priority.

Regards.

May 3, 2024 at 9:47 am #15590668

Fiyinfoluwa Lasaki

Hi! Not gonna lie, most of the contents in the loom video are confusing. But to understand you, my current solution would be to do this right? WPML > Settings > Custom post type translation, find "Tickets Commerce Tickets (tec_tc_ticket)" and set it as "not translatable" and then create the events tickets manually on each translation. is that correct?

May 3, 2024 at 10:22 am #15590770

Fiyinfoluwa Lasaki

So I tried doing as you said above but the checkout doesn't still come up on the translated pages. I created a new event in English and created the same ticket in the German language..it shows on the frontend of the site but the payment widget doesn't come up, so they can't still purchase

Screenshot 2024-05-03 at 11.18.24 AM.png
Screenshot 2024-05-03 at 11.18.04 AM.png
Screenshot 2024-05-03 at 11.17.42 AM.png
May 3, 2024 at 1:36 pm #15591613

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Can you allow me to set everything up for you on one event? that way i can record myself while i do it so you can see all the steps needed in a "cleaner" way.

--------------------
By the way, we're trying to contact the authors of the plugin again to see if this time we get an answer about this 🙂

May 3, 2024 at 1:41 pm #15591618

Fiyinfoluwa Lasaki

Please go ahead and set it up on an event, and also confirm that they're able to purchase tickets on the translated pages (i.e the card payment option pops up).

Thank you, I will also reach out to the events plugin but I just need something that works now, I'm getting a lot of pressure on this.

I'll be expecting your response ASAP

May 3, 2024 at 2:25 pm #15591746

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Please check this video: hidden link

This configuration seems the more stable. however the payment part is not appearing on the translated versions. i wonder how do you configure the payment methods and where so we can then try to understand why they are not loading on the translated languages.

Let me know, please.

May 3, 2024 at 2:49 pm #15591818

Fiyinfoluwa Lasaki

It is configured under settings >> payments of the tickets plugin on the left-hand side panel. I have also checked what could be wrong

May 3, 2024 at 3:00 pm #15591870

Fiyinfoluwa Lasaki

I have attached an image to show you the payment option.

Screenshot 2024-05-03 at 3.58.55 PM.png
May 3, 2024 at 3:38 pm #15591964

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Ok found the problem and even applied the fix which is a code on the functions.php file of your site:

/**
 * Translate page ID for WPML.
 * 
 * @link wpmlsupp-11347
 * @param mixed $page_id 
 * @return mixed 
 */
function wpmlsupp_11347_translate_page_id( $page_id ) {
	return apply_filters( 'wpml_object_id', $page_id, 'page', true );
}
add_filter('tec_tickets_commerce_checkout_page_id', 'wpmlsupp_11347_translate_page_id');
add_filter('tec_tickets_commerce_success_page_id', 'wpmlsupp_11347_translate_page_id');

The problem comes from "events ticket" which is sadly not compatible with WPML so i'd strongly suggest you talk to the events calendar authors and let them know about it. we're trying to contact them but they will definitely appreciate more if they actually have proof of interest from clients.

-----------
By the way and not related to the problem but quite important since you have custom coding in your theme at the moment: you should use a child theme in this case, otherwise the code will be wiped out with a theme update (you have an available update for the theme, so be aware of this).

Regards.