Description

Filter hook to redirect the user upon login.

Parameters

$redirect_to
(string)(required) The URL to redirect the user to.

$user_id
(integer)(optional) The user’s primary key ID.

Changelog

Introduced in 2.7.7

$user_id argument added in 2.9.2

Source

wpmem_login_redirect is located in wp-members-core.php

Usage

add_filter( 'wpmem_login_redirect', 'my_login_redirect', 10, 2 );

function my_login_redirect( $redirect_to, $user_id ) 
{
	// return the url that the login should redirect to
	return 'http://yourdomain.com/your-page';
}

Examples

See a list of all filter and action hooks

Private

You do not have permission to view this forum.