How to Redirect Users after Successful Login in WordPress

Поделиться
HTML-код
  • Опубликовано: 31 май 2024
  • Are you wanting to redirect users to a specific page after they log in to your WordPress site? Depending on the user's role WordPress normally sends them to the dashboard or their profile in the admin area. In this video, we'll cover two methods to redirect users after they successfully log in to WordPress.
    This video brought to you by WPForms, take a look at their site here:
    =================================
    wpforms.com/
    =================================
    For the discount, use our code: WPBVIP
    For the first method we'll cover, we will be using Peter's Login Redirect plugin found here:
    wordpress.org/plugins/peters-...
    Once you install and activate the plugin you will want to go under Settings, Login/logout Redirects to set up the plugin's settings. In the settings page, you can choose to redirect for a specific user once they log in, or a specific user role and you can check under the plugin settings to decide what capability a user needs to edit the options, we recommend install plugins to limit this to admin users. Don't forget to save the specific sections and the options page itself to ensure that it saves all of your customizations.
    For the second method we recommend, we will be using WPForms Pro version to create our login page. Once you install and activate the plugin (you can receive a discount with the code above) you would activate the user registration addon and create a new form, ours will start with the preset User Login Form template. With the form setup, under Settings, Confirmation we will set the confirmation to go to a URL of our choice and save the settings.
    If you liked this video, then please Like and consider subscribing to our channel here for more WordPress videos.
    ruclips.net/user/subscription_...
    Feel free to take a look at the written version of this tutorial here:
    www.wpbeginner.com/plugins/ho...
    Check us out on Facebook
    / wpbeginner
    Follow us on Twitter
    / wpbeginner
    Check out our website for more WordPress Tutorials
    www.wpbeginner.com
    #WordPress #WordPressTutorial #WPBeginner
  • ХоббиХобби

Комментарии • 45

  • @adammoumou3357
    @adammoumou3357 3 года назад +1

    You are a very good teacher, Thank you so much.

    • @wpbeginner
      @wpbeginner  3 года назад

      Glad our guide was helpful :)

  • @clakmal9
    @clakmal9 4 года назад +1

    This is so useful thank you

  • @lisandrogomez6140
    @lisandrogomez6140 4 года назад +1

    thanks, youll gays worked my problem!

    • @wpbeginner
      @wpbeginner  4 года назад +1

      Glad our guide could help :)

  • @hurpeyeahmie
    @hurpeyeahmie Год назад

    Thank You so much. please when user is in Landing page, is there a way you can change the header and footer in such a way that it will be different from other user. changing UI

    • @wpbeginner
      @wpbeginner  Год назад +1

      It would depend on how specific you wanted to be, if you wanted it for different roles then you can follow our guide below:
      www.wpbeginner.com/plugins/how-to-add-conditional-logic-to-menus-in-wordpress/

  • @evangauer
    @evangauer 4 года назад

    Am I able to have users create an account through a plug-in like Ultimate Membership Pro and then direct that specific user to their own page?

    • @wpbeginner
      @wpbeginner  4 года назад

      It would depend on what you mean by their own page, if you reach out to Ultimate Membership Pro's support they should be able to let you know

  • @SdotFive
    @SdotFive 3 года назад +1

    Great video. Now can we get one that doesn't involve a plugin? Im using the 'login_redirect' hook. My function fires as desired. It just doesn't go to the desired URL. I used home_url('/slug-name') and used the complete URL. Neither worked

    • @SdotFive
      @SdotFive 3 года назад

      nvm.....i just needed to refresh the page smfh lmfaoo. The "home_url('/slug-name')" method worked fine

    • @wpbeginner
      @wpbeginner  3 года назад

      Glad it worked :)

  • @cmdigitalmediahawaiii5028
    @cmdigitalmediahawaiii5028 3 года назад

    Love your videos. They are so helpful. After someone logs in and gets redirected to a page, how do you make that page restricted so only they can see it? For instance, if i have a page with videos that only someone logged in can see?

    • @wpbeginner
      @wpbeginner  3 года назад +1

      For what it sounds like you're wanting, you would want to take a look at membership plugins for that option. We have a few options in our article below:
      www.wpbeginner.com/plugins/5-best-wordpress-membership-plugins-compared/

    • @cmdigitalmediahawaiii5028
      @cmdigitalmediahawaiii5028 3 года назад

      @@wpbeginner thank you I will look more into that !🤙🏽

  • @anonymouscreature3631
    @anonymouscreature3631 3 года назад

    Hey! I want to restrict specific page to get accessed by the users only who are logged in (login pop up should be shown on that page) Only after login user can access or read that page. So is there any plugin or any other way for it??

    • @wpbeginner
      @wpbeginner  3 года назад +1

      You would want to look into membership plugins for something like that. For a few options you could take a look at our article below:
      www.wpbeginner.com/plugins/5-best-wordpress-membership-plugins-compared/

  • @YovesMunala
    @YovesMunala 4 года назад +1

    Thanks for the video but have tried to use peter's login but it is not redirecting me to my home page.... What might be the problem

    • @wpbeginner
      @wpbeginner  4 года назад

      Not sure, if you reach out to the plugin's support they should be able assist with the issue.

  • @Isthatyoudear
    @Isthatyoudear 4 года назад

    Bit what about Wordpress.com users? This seems only to work for .org. I don't wish to change right now so how do I go about installing a privacy policy page/button/pop-up despite this? Thanky you.

    • @wpbeginner
      @wpbeginner  4 года назад

      Our tutorials are for WordPress.org sites, you would want to reach out to WordPress.com for their current system for setting this up.

  • @chatkay6823
    @chatkay6823 4 года назад

    that was usefull i subscribe for you

    • @wpbeginner
      @wpbeginner  4 года назад

      Glad our guide was useful :)

  • @nikshayrana
    @nikshayrana 3 года назад

    Can you please guide me how can I make a different home page(login page) for unlogged users and can redirect them to site's main home page(home page for logged in users)?
    Thank You :)

    • @wpbeginner
      @wpbeginner  3 года назад

      For what you're wanting, you would want to look into membership plugins like the ones we list in our article below:
      www.wpbeginner.com/plugins/5-best-wordpress-membership-plugins-compared/

  • @YucheeDy
    @YucheeDy 2 года назад

    any video about how to redirect to new window after start play the movie or video?

    • @wpbeginner
      @wpbeginner  2 года назад

      We do not have a beginner friendly method we would recommend for that at the moment.

  • @DJLanta
    @DJLanta 3 года назад

    How do I make it redirect from a 404 page though? I can’t figure it out.

    • @wpbeginner
      @wpbeginner  3 года назад

      You have a few options available, for a starting point you may want to take a look at the plugins we recommend in our article below:
      www.wpbeginner.com/showcase/6-best-free-404-plugins-for-wordpress/

  • @digiweb4357
    @digiweb4357 2 года назад

    created user not working for my wbsite
    redirecting to home page when im trying to login

    • @wpbeginner
      @wpbeginner  2 года назад

      If it is not intended then you would want to take a look at our article below:
      www.wpbeginner.com/wp-tutorials/how-to-fix-wordpress-login-page-refreshing-and-redirecting-issue/

  • @benjaminbrunelle8084
    @benjaminbrunelle8084 4 года назад

    I need HELP please ! I can't spend another 12 hours trying to fix my issue. I have a Login and Logout issue for customers. When you click Login (nothing happens, redirects to my account page) doesn't log you in. It magically Logged me in but now I cannot Logout as a customer. I have tried looking into my pages, my appearance menus list, my plugins, Tried editing it with my theme and nothing... Please Help

    • @wpbeginner
      @wpbeginner  4 года назад

      It would depend on what you are using on your site if we're understanding correctly. If a user is not logged in they would want to log into your site rather than login without their information.
      You logged into your site likely because your browser's cookies had your login information set up. To log out, you would want to check the top right of the page for an option to log out.

  • @marktaylor8274
    @marktaylor8274 4 года назад

    How do I bypass the log in screen after the user has received email confirmation

    • @wpbeginner
      @wpbeginner  4 года назад

      It would depend on your settings but for your admin area you would normally want to go to /wp-admin on your site

  • @rafatmk
    @rafatmk 3 года назад

    how to ask for user registration then redirect them to the page after login..how can you miss that logical step as the user has to create user login before actually logging in

    • @wpbeginner
      @wpbeginner  3 года назад

      We cover the different methods to allow and request user registration in our article below:
      www.wpbeginner.com/beginners-guide/how-to-allow-user-registration-on-your-wordpress-site

  • @Iris-qh2pl
    @Iris-qh2pl 2 года назад

    This has changed now and I can’t manager redirect rules in settings anymore

    • @wpbeginner
      @wpbeginner  2 года назад

      Thank you for letting us know, it looks like the plugin has added its own settings area under LoginWP

  • @KevsGuide
    @KevsGuide 2 года назад

    thanks i just want a download button and then have them sent to a thankyou page after the download - no optin

    • @wpbeginner
      @wpbeginner  2 года назад

      You have a few options depending on if you are looking for any other features. We would recommend looking at the options from our list below:
      www.wpbeginner.com/plugins/best-wordpress-download-manager-plugins-compared/

  • @AshokElectronicsVideoMAX
    @AshokElectronicsVideoMAX 3 года назад

    How and where can I add User Name and their passwords ? How many Users can I add ? Thanks in advance

    • @wpbeginner
      @wpbeginner  3 года назад +1

      If you want to manually add a user you would do so in your wp-admin area under Users, All Users and click the add new button at the top

    • @AshokElectronicsVideoMAX
      @AshokElectronicsVideoMAX 3 года назад

      @@wpbeginner thanks very much, will try.