l just wanna change words "wordpress x.x.x running on theme"in "At a glance",actually l wanna remove the link "theme.php".l added the code in my function.php:
add_filter('gettext', 'remove_admin_stuff', 20, 3);
function remove_admin_stuff( $translated_text, $untranslated_text, $domain ) {
$custom_field_text = 'You are using <span class="b">WordPress %s</span>.';
if ( is_admin() && $untranslated_text === $custom_field_text ) {
return '';
}
return $translated_text;
}
wanna make a trick.but it failed .please help me.
l just wanna change words "wordpress x.x.x running on theme"in "At a glance",actually l wanna remove the link "theme.php".l added the code in my function.php:
add_filter('gettext', 'remove_admin_stuff', 20, 3);
function remove_admin_stuff( $translated_text, $untranslated_text, $domain ) {
$custom_field_text = 'You are using <span class="b">WordPress %s</span>.';
if ( is_admin() && $untranslated_text === $custom_field_text ) {
return '';
}
return $translated_text;
}
wanna make a trick.but it failed .please help me.
Share Improve this question asked Mar 15, 2019 at 9:53 Leon ZhaoLeon Zhao 11 bronze badge 1 |1 Answer
Reset to default 0This code may help you.
function wpfi_change_text( $translated_text ) {
if ( $translated_text == 'ORIGINAL TEXT' ) {
$translated_text = '';
}
return $translated_text;
}
add_filter( 'gettext', 'wpfi_change_text', 20 );
$translated_text
which was not modified. – Max Yudin Commented Mar 15, 2019 at 10:18