• Resolved leost

    (@leost)


    Hello,

    I already know how to redirect the user to the account page on login. But is it possible to load the account page in a different tab?

    For example, on login open the account page and show the privacy tab, like in this image instead of the account tab.

    Thanks!

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

    (@champsupertramp)

    Hi @leost

    You can just add the direct URL in the Login options > Action to be taken after login > redirect to URL.

    Example: yoursite.com/account/privacy/

    Regards,

    Thread Starter leost

    (@leost)

    Hey @champsupertramp!

    When I try to directly access yoursite.com/account/privacy/ it redirects to yoursite.com/account/. Do you think this happens because I translated the account page to conta or it has nothing to do? Instead of yoursite.com/account/privacy/ it’s yoursite.com/conta/privacy/.

    By default, does the redirection works differently for admins and custom created users?

    Thanks!

    Plugin Contributor Champ Camba

    (@champsupertramp)

    Hi @leost

    You can try the URL yoursite.com/conta/privacy/ in the Redirection option instead.

    Administrator and Subscriber roles have their own User role settings and redirection options.

    Regards,

    Thread Starter leost

    (@leost)

    Hey @champsupertramp!

    Sorry, I wasn’t very clear. In portuguese account translates to conta, so I translated the account page to conta and I thought that maybe the fact that I translated that page name and slug it could be causing the redirection.

    I am already using yoursite.com/conta/privacy/ in the url and it is redirecting to yoursite.com/conta/theusername. My only doubt is related to the account page, where there is the tab menu. The only way I can change tabs is by cliking them. If i try to copy and paste and hit enter using a different url (privacy for example), it will redirect.

    I guess that this is the default behavior of the plugin, it will always redirect to the first tab on the account page, right?

    Thanks!

    Plugin Contributor Champ Camba

    (@champsupertramp)

    Hi @leost

    You can try the following code snippet to make the privacy tab active on visiting the /conta/ page:

    add_action("init", function(){
        UM()->account()->current_tab = "privacy";
    });

    You can add the code to your theme/child-theme’s functions.php file or use the Code Snippet plugin to run the code.

    Regards,

    Thread Starter leost

    (@leost)

    It works. Thank you!

    Plugin Contributor Champ Camba

    (@champsupertramp)

    Thanks for letting us know.

    Regards,

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Login redirect account page specific tab’ is closed to new replies.