Support » Plugin: Theme My Login » Editing message on Registration Page

Viewing 4 replies - 1 through 4 (of 4 total)
  • Put this in your theme’s functions.php file and change the $message variable to suit your self.

    function tml_action_template_message_filter( $message, $action ) {
    	if ( 'register' == $action ) {
    
    	$message = 'Replace this with your new message';
    
    	}
    
    	return $message;
    }
    
    add_filter( 'tml_action_template_message', 'tml_action_template_message_filter', 10, 2 );

    This is what I currently use which includes logic for the register and reset password pages. I wanted to remove the default messages that appear before any action has actually taken place so I left the $new_message variable empty. Add whatever messages you need though.

    function tml_messages( $message, $action ) {
    
    		switch ( $action ) {
    			case 'register' :
    				$new_message = '';
    				break;
    			case 'lostpassword' :
    				$new_message = '';
    				break;
    			case 'resetpass' :
    				$new_message = '';
    				break;
    		}
    
    	if($new_message) return $new_message;
    }
    
    add_filter( 'tml_action_template_message', 'tml_messages', 10, 2 );
    Thread Starter SapphireFoxx

    (@sapphirefoxx)

    I tried both of those and neither seemed to affect the registration page at all.

    Where did you put the function ?
    Do you cache your pages ?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Editing message on Registration Page’ is closed to new replies.