Problema: Stai migrando dati da un sito immobiliare multilingue a una nuova configurazione utilizzando il plugin WP All Import Pro insieme all'add-on Houzez e WPML per le traduzioni. Hai bisogno di mantenere gli ID originali per preservare le relazioni esistenti tra agenti, proprietà e traduzioni. Durante il processo di importazione, WordPress genera nuovi ID sia per le proprietà che per gli agenti, e non è chiaro come assicurare che tutte le traduzioni per proprietà e agenti siano correttamente connesse e collegate alle loro versioni originali. Soluzione: Le traduzioni non possono avere lo stesso ID degli originali perché sono post diversi e ciò causerebbe un errore fatale. Questo è dovuto al funzionamento di WordPress, non a WPML. Se stai importando questi contenuti in un sito già esistente che non è vuoto, è probabile che gli ID dei contenuti importati siano già assegnati a qualche altro post, quindi WPML non può utilizzare gli stessi ID che avevi nel vecchio sito. Purtroppo, WPML non dispone di hook o strumenti per mappare i record importati alle loro corrispondenti traduzioni basate su un identificatore unico esterno. L'unica soluzione è rimappare le relazioni manualmente.
Se questa soluzione non risolve il tuo problema o sembra non essere più attuale, ti consigliamo di aprire un nuovo ticket di supporto. Ti raccomandiamo inoltre di controllare i problemi noti, verificare la versione della correzione permanente e confermare che hai installato le ultime versioni di temi e plugin. Per ulteriore assistenza, visita il forum di supporto WPML.
Problem: You are trying to remove WooCommerce's strings from the database using the 'Remove strings by domain' feature, but it has no effect. Even though you receive a success message, the strings remain in the database. Solution: 1. The 'Remove strings by domain' feature only deletes untranslated strings. If the string is translated, it won't be affected. 2. To delete strings manually, go to String Translation, select the WooCommerce text-domain, and delete the strings. You can show all results using the "Strings per page:" filter below the strings table. 3. If you need to remove strings directly from the database, use the following SQL queries:
DELETE FROM wpif_123_icl_strings WHERE context = 'woocommerce';
DELETE FROM wpif_123_icl_string_translations WHERE string_id IN (SELECT id FROM wpif_123_icl_strings WHERE context = 'woocommerce');
Please note that this custom code is a courtesy and is not officially supported by us. Before applying it to a live site, please test it in a staging environment.
If this solution does not apply to your case, or if it seems outdated, we recommend opening a new support ticket. We also 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. For further assistance, please visit our support forum at https://wpml.org/forums/forum/english-support/.
Problem: You have created an ACF select field and are trying to dynamically pass a list of posts filtered by language using a filter. Solution: We recommend creating a new variable to capture the current language using the WPML hook. You can find more information about this hook here: https://wpml.org/wpml-hook/wpml_current_language/ Example:
Then, use a conditional statement to filter the posts by the language code. Here are two examples of how you can implement this:
// Conditional switch statement based on the current language
switch ( $current_language ) {
case 'fr':
// your French post IDs
break;
default:
// Default case for default language post IDs
break;
}
or
// Conditional logic based on the current language
if ( $current_language === 'fr' ) {
// your French post IDs
} else {
// your English post IDs
}
If this solution does not resolve your issue or seems outdated, 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. We highly recommend opening a new support ticket if needed.
Problem: If you're experiencing a PHP Fatal error when updating a product variant in WooCommerce that exists only in a non-main language, it might be due to the variant's original ID missing in the database. This issue can occur if the original variant was removed while WPML was disabled or due to an external process, leading to potential database corruption. Solution: We recommend running the ghost cleanup process in WPML to resolve this issue. Please navigate to: WPML → Support → Troubleshooting Then, select: "Remove ghost entries from the translation tables". This action should help clear any discrepancies in the database related to missing original IDs.
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 the problem persist, please do not hesitate to open a new support ticket at WPML support forum for further assistance.
Problem: El cliente necesita que el desplegable de idioma en la versión móvil de su sitio web se abra hacia arriba, ya que la cabecera está en la parte inferior en esta versión. Además, desea mostrar solo las iniciales de los idiomas en el desplegable, sin banderas. Solution: Para que el desplegable de idioma se abra hacia arriba en la versión móvil, es necesario crear una solución personalizada, ya que WPML no ofrece esta opción por defecto. Recomendamos contactar a uno de nuestros partners certificados para desarrollar esta funcionalidad. Además, para cambiar la visualización en el desplegable a solo iniciales de idiomas, siga estos pasos: 1. Vaya a WPML -> Idiomas -> Sección 'Idiomas' -> Click en el enlace de editar idiomas. 2. Cambie el nombre de los idiomas a sus iniciales. 3. Guarde los cambios.
Si esta solución no resuelve su problema o si la información proporcionada se ha vuelto obsoleta, le recomendamos abrir un nuevo ticket de soporte. También es aconsejable revisar los problemas conocidos y asegurarse de que tiene instaladas las últimas versiones de los temas y plugins. Para más asistencia, visite nuestro foro de soporte.
Problem: The client is unable to translate the cookies notice on their website after modifying the text, and the provided WPML documentation did not resolve their issue. Solution: We recommend updating the gettext code in your theme or plugin files to ensure proper translation string and text domain usage. Here are the steps: 1. Update your gettext code to include the correct text domain and ensure the URL is wrapped appropriately for translation. For example:
<div class="message"><br /> <?php echo sprintf(<br /> esc_html__( 'We use cookies to improve your user experience. %s', 'your-text-domain' ),<br /> '<u><b><a href="https://mp-performance.ae/privacy-policy">' . esc_html__( 'Learn more', 'your-text-domain' ) . '</a></b></u>' <br /> ); ?><br />
2. Scan the theme or plugins for strings using WPML's String Translation. 3. Translate the strings as needed in WPML.
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. If issues persist, please open a new support ticket.
Problem: If you're experiencing issues where the language selector does not change the language on blog posts, and instead links to the current language rather than the selected alternate language, the issue might be with your theme's functions.php file. Solution: In this case, the issue was caused by a function inside the functions.php file of a Child Theme:
This code modifies the blog post links and can interfere with the WPML language switcher. Removing this snippet should allow the language switcher to function correctly.
If this solution does not resolve your issue, or if it seems outdated or irrelevant to your case, we highly recommend checking related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. Additionally, you can open a new support ticket for further assistance at WPML support forum.
Problema: Se nella tua homepage italiana, nella sezione delle ultime notizie, vedi post tradotti in inglese anziché solo quelli in italiano, il problema potrebbe derivare dall'uso di un template custom che non include filtri per le lingue. Soluzione: Ti consigliamo di modificare il template utilizzando gli hook di WPML. Un esempio utile è l'uso di wpml_object_id. Se questa soluzione non risolve il problema o se sembra non essere più attuale, ti invitiamo a verificare i problemi noti correlati, a controllare la versione della correzione permanente e a confermare che hai installato le ultime versioni dei temi e dei plugin. In caso di ulteriori difficoltà, ti suggeriamo di aprire un nuovo ticket di supporto.
Problem: The client needed to synchronize products between Dutch and German versions on their website, using the same SKU for each product. They encountered issues where the German version of a page was not displaying correctly, even though it was published. Solution: We advised the client to use the WPML export and import tool to link translations together, which can be found here: WPML Export and Import documentation. Additionally, for the issue with the German page not displaying, it was discovered that the page was still in drafts, and we recommended publishing it through the language switcher on the admin bar. For the broader issue of synchronizing products, we suggested exporting all feeds and merging them into a single CSV file for each language. This approach allows for the use of the 'Automatic Record Matching to Translate' feature during the import process. We recommended testing this solution on a sandbox site to ensure the correct setup of the 'import template'.
If this solution does not resolve your issue, or if it seems outdated or irrelevant to your case, please check the related known issues at WPML Known Issues and confirm that you have installed the latest versions of themes and plugins. If further assistance is needed, we highly recommend opening a new support ticket at WPML Support Forum.
in Swagger documentation while using the WP API SwaggerUI plugin to ensure consistency with your REST API structure. You could not find information on modifying this field in the WP API SwaggerUI plugin or WPML documentation. Solution: We do not provide a built-in option to rename the
wpml_language
field directly in the REST API. However, you can modify the API response using filters or by extending the WP API SwaggerUI plugin. If you need further help with custom coding, we recommend hiring WPML contractors. You can find them here: https://wpml.org/contractors/
Please note that this solution might be outdated or not applicable to your specific case. 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. If this does not resolve your issue, please open a new support ticket at WPML support forum.
Problem: You want the translation column to always be visible on the WooCommerce product list in the admin area, but even after using a code snippet to unhide the column, no data is displayed in it. Solution: We recommend implementing a custom function to ensure the 'icl_translations' column is always visible and contains data. Here's a step-by-step guide: 1. Add the following function to your theme's functions.php file or a custom plugin:
Please test this solution in a staging environment before applying it to your live site, as this custom code is a courtesy and not officially supported by us.
If this solution does not resolve your issue or 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. If further assistance is needed, please open a new support ticket at WPML support forum.
Problem: The client is using a custom script to update stock and prices of products via the WooCommerce API. This script updates only the main language, and while the stock and prices reflect correctly across all languages, the translations for product names and descriptions are reset to match the main language. Solution: 1. We recommend checking if the 'save_post' hook is being executed after updates. This hook helps ensure that changes are properly synchronized across translations. 2. Verify if the WPML translation editor is disabled for the products. If it's not, any save in the default language might reset manually added translations. For more details on using different translation editors, visit Using Different Translation Editors for Different Pages. 3. If products were duplicated using WPML's 'Translation Management', check the post meta table for 'icl_duplicate_of' and delete if any entries are found. This can prevent content from syncing/duplicating incorrectly on save.
If these steps do not resolve the issue or if the solution seems outdated or irrelevant to your case, 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. If the problem persists, please open a new support ticket at WPML support forum.
Problem: The client needed to customize the hover effect color of the language button from black to blue (#002fa7) and the background color of the alternative language options from grey to light blue (#B3E5FF) in WPML.
Solution: We fixed this by adding the following CSS code in the WordPress Customizer under Appearance -> Customize -> Additional CSS:
Please note that this solution might be outdated or not applicable to your specific case. 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. If this does not resolve your issue, please open a new support ticket at WPML support forum.
Problem: You are trying to capture the language of the customer in WooCommerce orders using WPML, but the meta key 'wpml_language' does not work. Solution: The correct meta key to use is 'wpml_languages', which is stored in the 'wp_wc_orders_meta' table. This key reflects the language of the order based on the active user language at the time the order is created on the frontend. Here is how you can retrieve the language from the 'wpml_languages' meta key:
$order = wc_get_order( $order_id );
// Retrieve the 'wpml_languages' meta value
$wpml_languages = $order->get_meta( 'wpml_languages' );
// If the data is serialized, unserialize it
if ( !empty( $wpml_languages ) ) {
$languages = unserialize( $wpml_languages );
// Assuming the first entry is the primary language of the order
$order_language = isset( $languages[0] ) ? $languages[0] : null;
// Output or use the $order_language
echo 'Order language: ' . $order_language;
}
If this solution does not resolve your issue, or if it seems outdated or irrelevant to your specific case, 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. If further assistance is needed, please open a new support ticket at WPML support forum.