Support » Fixing WordPress » Change login-footer Back to blog text

Viewing 2 replies - 1 through 2 (of 2 total)
  • Caspar Hübinger


    I don’t think WordPress lets you do that. login_footer() is called without any filtering in line 942, so you would have to replace the whole file – which you don’t want as its file name is hard-coded in several places.

    The only chance I can think of would be a javascript hack. You could call a script via add_action( 'login_footer', 'your-script-call' ) and try to manipulate #backtoblog in the front-end.



    Ok. I thought I could remove the function and replacing it with a custom one, through my functions.php. I just don’t know how to accomplish that.

    I found this solution which searches for the textstring and replaces it with a custom string, here: Back to %s without the left arrow. %s gives get_bloginfo(‘title’). I would like to replace that with get_bloginfo(‘url’). Any ideas anyone?

    function back_to_site_text( $translated ) {
        if ( in_array( $GLOBALS['pagenow'], array( 'wp-login.php', 'wp-register.php' ) ) )
            $translated = str_ireplace(  '← Back to %s', 'Back to %s',  $translated );
            return $translated;
     add_filter('gettext', 'back_to_site_text');
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Change login-footer Back to blog text’ is closed to new replies.