Link to edit profile screen within same admin if in network or user admin.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16475 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
76f3dd920b
commit
374cfa11b4
|
@ -2319,7 +2319,12 @@ function get_dashboard_url( $user_id, $path = '', $scheme = 'admin' ) {
|
|||
function get_edit_profile_url( $user, $scheme = 'admin' ) {
|
||||
$user = (int) $user;
|
||||
|
||||
$url = get_dashboard_url( $user, 'profile.php', $scheme );
|
||||
if ( is_user_admin() )
|
||||
$url = user_admin_url( 'profile.php', $scheme );
|
||||
elseif ( is_network_admin() )
|
||||
$url = network_admin_url( 'profile.php', $scheme );
|
||||
else
|
||||
$url = get_dashboard_url( $user, 'profile.php', $scheme );
|
||||
|
||||
return apply_filters( 'edit_profile_url', $url, $user, $scheme);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue