• Resolved Najib Habeb

    (@najibx)


    There’s a a front end and also backend. If a role has access to a backend, they can edit their profile using standard /wp-admin/profile.php, but UM fields is not shown here. How can we redirect /wp-admin/profile.php to their respective frontend profile edit like this : redirect to /[myprofilepage]/[username]/?um_action=edit

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor Champ Camba

    (@champsupertramp)

    Hi @najibx

    You can try this code snippets in your theme’s functions.php file or use the Code Snippets plugin to run the code:

    add_action("init","um_062821_redirect_profile");
    function um_062821_redirect_profile(){
        global $pagenow;
    
        if ($pagenow == 'profile.php') {
    
           wp_redirect( um_get_core_page("user") );
    
        }
    
    }

    The above code will redirect users to their profile when viewing the WP Admin > Profile page.

    Regards,

    Plugin Contributor Champ Camba

    (@champsupertramp)

    Hi @najibx

    Please feel free to re-open this thread by changing the Topic Status to ‘Not Resolved’ if any other questions come up and we’d be happy to help. ??

    Regards,

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Redirect to UM Profile edit when editing profile.php in backend’ is closed to new replies.