Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I've seen various tutorials on how to modify the menu items of a Wordpress Site's admin, but I'm trying to find a tutorial or way on how to modify the actual admin page labels. Here's what I mean:

When you are in the back end and you hover over SETTINGS, and click GENERAL, a page comes up with, of course, the general settings for the site. The labels for each input field are as follows: SITE TITLE, TAGLINE, WORDPRESS ADDRESS(URL), SITE ADDRESS(URL), etc.

I'm looking to add a function to my functions.php for a theme that will allow me to change these labels

Is this even possible? Or do I just have to hard code it in?

share|improve this question

2 Answers 2

up vote 0 down vote accepted

You can modify the labels using gettext filter hook ex:

add_filter( 'gettext', 'theme_change_label_names');
function theme_change_label_names($translated_text){
    if (is_admin()){
        switch ( $translated_text ) {

            case 'Site Title' :

                $translated_text = __( 'New Site Title label', 'theme_text_domain' );
                break;

            case 'Tagline' :

                $translated_text = __( 'new Tagline label', 'theme_text_domain' );
                break;
        }

    }

    return $translated_text;
}
share|improve this answer
    
I was worried right off the bat when I read this solution that it wouldn't apply to the p.description directly under the input field for the site description, but "slap me silly and call me susan".... –  Murphy1976 Jul 3 '12 at 14:11
    
Whatever you say Susan :) –  Bainternet Jul 3 '12 at 15:32

There are no filters applied to those labels, hence you cannot change it using a straight forward way. You may have to use a jQuery script for doing so. Don't hard code it, hard coding in core files is very bad!

The only things you can change in the General Settings page are the date formats and the time formats.

share|improve this answer
    
I kinda figured... –  Murphy1976 Jul 3 '12 at 13:19
    
Yep! :D I think they should give a filter to change the labels and an action to add more fields to this page. –  Rutwick Gangurde Jul 3 '12 at 13:29
    
Not true at all!!! –  Bainternet Jul 3 '12 at 13:52
    
Why so? I checked the core file options-reading.php. Is there some other way to do so? Did they add it in 3.4? Cuz I checked 3.1 or so... –  Rutwick Gangurde Jul 4 '12 at 5:15

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.