';
$message .= sprintf( __( 'In this version of WPML, you can give your taxonomy terms the same name across multiple languages. You need to update %d taxonomy terms on your website so that they display the same name without any language suffixes.', 'sitepress' ), $suffix_count );
$message .= '
';
}
ICL_AdminNotifier::addMessage( 'termssuffixnotice', $message, 'error', true, false, false, 'terms-suffix', true );
}
$sitepress->set_setting( 'taxonomy_names_checked', true, true );
}
// TODO: [WPML 3.3] the ICL_AdminNotifier class got improved and we should not call \ICL_AdminNotifier::displayMessages to display an admin notice
ICL_AdminNotifier::displayMessages( 'terms-suffix' );
}
/**
* Returns the HTML for the display of all terms with a language suffix in the troubleshooting menu.
*
* @return string
*/
public static function display_terms_with_suffix() {
$terms_to_display = WPML_Terms_Translations::get_all_terms_with_language_suffix();
$output = '';
if ( ! empty( $terms_to_display ) ) {
$output = '
';
$output .= '
';
$output .= '';
$output .= '
' . __( 'Remove language suffixes from taxonomy names.', 'sitepress' ) . '