3944 shaares
2034 private links
2034 private links
// File: functions.php
// Remove the "Catégorie :" part from page titles
// 2019-09-05, Kelly & Mika
// ᕦ(ò_óˇ)ᕤ
// Source: https://core.trac.wordpress.org/browser/tags/5.2/src/wp-includes/general-template.php#L1559
function remove_category_from_title( $translated_text ) {
if ( substr($translated_text, 0, 10) == 'Catégorie' ) {
$translated_text = trim(substr($translated_text, 13));
}
return $translated_text;
}
add_filter( 'gettext', 'remove_category_from_title', 20 );