Customize the “Registration complete. Please check your e-mail.” message on WP 4.0

If you need an alternative way, you can always hook into the login_init and modify the gettext filter: add_filter( ‘login_init’, function() { add_filter( ‘gettext’, ‘wpse_161709’, 99, 3 ); } ); function wpse_161709( $translated_text, $untranslated_text, $domain ) { $old = “Registration complete. Please check your e-mail.”; $new = “New text here”; if ( $untranslated_text === $old … Read more

Limit content by user registration date

I have just made this code you can try out: add_filter( ‘the_content’, ‘restrict_access’ ); function restrict_access( $content ) { $user_info = wp_get_current_user(); // Get logged in user info $registered = $user_info->user_registered; if( !is_user_logged_in() ) { $content = __( “You are not logged in.”, ‘your_textdomain’ ); } else if (new DateTime( get_the_date() ) < new DateTime( … Read more

User defined password at registration – registration email sends auto generated pass

Welcome to WPSE. You can use wp_insert_user, you don’t need to hook onto anything. Assuming here they fill out a form with a name, username, email and password field, and you capture it however you want. $name_array = explode(‘ ‘,$_POST[‘name’]); $user = array( ‘user_login’ => $_POST[‘username’], ‘user_pass’ => $_POST[‘password’], ‘user_email’ => $_POST[’email’], ‘first_name’ => $name_array[0], … Read more

How to turn off email you receive when registered?

The function that generates the new user notification is wp_new_user_notification(). It is called by another (similarly named) function wp_new_user_notifications() which is triggered by the action hook register_new_user in the register_new_user() function. If you follow that (or even if you don’t), all you need to do is remove the wp_new_user_notifications() filter from the register_new_user action: add_action( … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)