You can use filter generate_rewrite_rules to add new custom url! The first, you add filter to create url! Second, you add new function to handle that URL (display wordpress profile in this case)
add_filter('generate_rewrite_rules', 'axcoto_multi_rate_rewrite');
function axcoto_multi_rate_rewrite(&$wp_rewrite) {
$wp_rewrite->rules = array_merge(array('people/([^/]*)$' => 'index.php?pagename=people&username=$matches[1]'), $wp_rewrite->rules);
return $wp_rewrite;
}
That way when someone go to people/kureikain, wordpress will make it become index.php?pagename=people&username=kureikain
Then you createa a new page and make its slug to people! Next you create a new custom page template to display that profile!
Beside, we add a new query var, username to above code! We need to let wordpress knows about it
add_filter('query_vars', 'axcoto_multi_rate_query_vars');
function axcoto_multi_rate_query_vars($public_query_vars) {
$public_query_vars[] = 'username';
return $public_query_vars;
}
In your code, to get username, you must call
$username = get_query_var('username');
That's all!