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 am changing the text on the login page using this filter:

function filter_register_text() {
    return "<p class='message register'>Registering for this site will give you access to the admin panel to add new products with images and useful files for others to download and choose open product licenses.</p>";
}

add_filter('login_message', 'filter_register_text');

I just want to show the text if the user signs up on the website, not for users who just want to log in.

Thanks.

share|improve this question

1 Answer 1

up vote 3 down vote accepted

I think your best bet is to check if the action parameter is set & equal to register:

if ( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'register' )
    add_filter( 'login_message', 'filter_register_text' );
share|improve this answer

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.