`<?php
global $post;
if ( is_home()) {
global $current_user;
$log = $current_user->user_login;
if ( is_user_logged_in() ) :
header(‘Location: http://www.YOUR_DOMAIN_NAME.com/members/’.$log);
else :
header(”);
endif;
} else {
// User is not logged in – Display homepage
}
?>`
I’m looking to do something similar. Instead of going to the members profile page, I’d like to redirect members to their “default” group. It looks like I’ll need to write a short plugin which stores links between members and their default group in the custom user meta and allow that default to be edited in their profile.