Problem: The client is experiencing issues with author pages redirecting to the homepage instead of displaying the correct author page in various languages. This occurs when there are no posts available in the requested language.
Solution: This is the theme-specific issue that was not replicable on a new test site. We recommend using a custom code snippet to modify the behavior of the WPML language switcher on author pages. This code ensures that the language switcher links directly to the author pages, even if there are no posts in that language, thus preventing redirection to the homepage.
add_filter( 'icl_ls_languages', 'wpml_author_switcher_fix', 10, 1 );
function wpml_author_switcher_fix( $languages ) {
if ( is_author() ) {
$author = get_queried_object();
$author_slug = $author->user_nicename;
$default_lang = apply_filters( 'wpml_default_language', null );
foreach ( $languages as $lang_code => &$lang ) {
if ( $lang_code === $default_lang ) {
// No language prefix for default language
$lang['url'] = '/author/' . $author_slug . '/';
} else {
$lang['url'] = '/' . $lang_code . '/author/' . $author_slug . '/';
}
}
}
return $languages;
}
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 the issue persists, please open a new support ticket at WPML support forum.
Problem: Sie haben eigene hreflang Einträge mit einem Script erstellt und möchten die automatischen hreflang Einträge von WPML abschalten. Trotz Deaktivierung über wp-config.php und SEO-Einstellungen bleiben die WPML hreflang Einträge bestehen. Solution: Um die hreflang Einträge von WPML vollständig zu unterdrücken, können Sie folgenden Code verwenden:
Bitte beachten Sie, dass dieser Code zu unerwarteten Problemen führen könnte. Alternativ können Sie WPML's hreflang Einträge mit einem speziellen Hook überschreiben, den Sie hier finden: WPML alternate hreflang Hook.
Falls diese Lösung veraltet ist oder nicht auf Ihr Problem zutrifft, empfehlen wir Ihnen, ein neues Support-Ticket zu eröffnen. Wir empfehlen auch, die Seite mit bekannten Problemen (bekannte Probleme) zu überprüfen, die Version der dauerhaften Lösung zu verifizieren und zu bestätigen, dass Sie die neuesten Versionen von Themes und Plugins installiert haben. Für weitere Unterstützung besuchen Sie bitte unser Support-Forum: WPML Support-Forum.
Problem: If you're experiencing issues with translating relationships in JetEngine using WPML, where the expected content is not translated, this might be due to missing relationships between the translated categories. Solution: We recommend checking if the relationships between your primary category (e.g., 'Industry') and its related product categories are correctly established in the translations. In a case where a category like 'Cafes' is not showing the translated content, you should: 1. Go to Products -> Industry in your WordPress dashboard and switch to the English interface. 2. Open the English term 'Cafes', scroll to the bottom, and manually connect the appropriate English translated child categories. This action should help in displaying the related categories correctly on the translated page.
If this solution does not apply to your case, or if it seems outdated, we highly recommend checking the related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. Should you need further assistance, please do not hesitate to open a new support ticket.
Problem: The client wants to remove WPML menu links from the Appearance > Menus page in the WordPress admin area. Solution: We explained that these links are essential for creating different menus in various languages and recommended not removing them. However, if the client insists on hiding these links from the UI without affecting the functionality, we suggested injecting custom CSS. Here is the code to add to the functions.php file or a custom plugin:
Please note that handling custom code is generally beyond our support scope, and we recommend consulting an independent developer for further customization.
If this solution does not apply to your case, or if it seems outdated, please check the related known issues, verify the version of the permanent fix, and confirm that you have installed the latest versions of themes and plugins. If issues persist, we encourage you to open a new support ticket.
Problem: The client is experiencing an issue where the translation of certain elements on the Projects page is not working correctly. Specifically, the buttons using a custom taxonomy ("proj_status") to filter a list of custom posts ("project") are not translating correctly in some languages, showing both translated and English versions. Solution: We checked the shortcode [eb5capital_projects] used for displaying the filters. We then configured the option in WPML > Settings > Taxonomies Translation > Status (proj_status) > Translatable - only show translated items. This adjustment resolved the issue.
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 WPML Support Forum.