Home User profile
tagDiv Member
This user did not write anything. So we are just showing here some random text to make the profile page look nice :)
panos.fasoulis
tagDiv Member

Now I seem to have notice a different issue altogether and upon disabling all my custom edits i saw that this was happening from the start I just never noticed it.

When someone logs in from the tagdiv login page it redirects them to the same page eg from my-custom-tag-div-login to my-custom-tag-div-login/#

But when they enter their user credentials again for the second time it seems to log the user normally…

Anyone noticed something similar before?

panos.fasoulis
tagDiv Member

i fixed it by adding the following in functions.php I am going to leave it here in case someone needs it. But i am still curious if i did something wrong and there was an easier way like with the password

add_filter( ‘wp_mail’, ‘custom_modify_activation_email’, 10, 1 );
function custom_modify_activation_email( $args ) {
// Check if email is activation email by looking for unique strings.
// subject “Activate account” message “action=tds_validate”.
if ( strpos( $args[‘subject’], ‘Activate account’ ) !== false ||
strpos( $args[‘message’], ‘action=tds_validate’ ) !== false ) {
$args[‘message’] = str_replace( ‘wp-login.php’, ‘my-custom-login-page’, $args[‘message’] );
}
return $args;
}
add_action(‘template_redirect’, function() {
if ( isset($_GET[‘action’]) && $_GET[‘action’] === ‘tds_validate’ && strpos($_SERVER[‘REQUEST_URI’], ‘my-custom-login-page’) !== false ) {
$query_string = $_SERVER[‘QUERY_STRING’];
wp_redirect( site_url(‘/wp-login.php?’ . $query_string), 301 );
exit;
}
});

Viewing 2 posts - 1 through 2 (of 2 total)