I’m trying to change the “Excerpt” label in the admin to “Dek”; I’ve been looking around and it seems that this should work:
add_filter( ‘gettext’, function( $translated_text ) {
if ( ‘Excerpt’ === $translated_text ) {
$translated_text = ‘Dek’;
}
return $translated_text;
} );
But it’s not doing anything. I have it in functions.php (does it need to go within something?). Also, is anything special needed to make it work on all custom post types? (I have been testing on the regular Posts, but will need it elsewhere as well)