Title: Redirection after login
Last modified: June 24, 2019

---

# Redirection after login

 *  Resolved [Vincent Poirier](https://wordpress.org/support/users/magikweb/)
 * (@magikweb)
 * [6 years, 12 months ago](https://wordpress.org/support/topic/redirection-after-login-5/)
 * Hello,
    This plugin is marvelous so far, the only issue I have is to redirect
   after login (to a different site). I tested the following code (2 tests), but
   upon logging in, the user is redirected to the homepage.
 *     ```
       function pugs_after_auth($wp_user, $exlog_user_data) {
           wp_redirect( 'myurlhere?username=' . $exlog_user_data['user_login'] );
           exit;
       }
       add_action('exlog_hook_action_authenticated', 'pugs_after_auth', 10, 2);
   
       add_filter( 'login_redirect', function( $url, $query, $user ) {
       	return 'https://google.ca';
       }, 10, 3 );
       ```
   
 * Anyone knows if I’m forgetting something?

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [tbenyon](https://wordpress.org/support/users/tbenyon/)
 * (@tbenyon)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/redirection-after-login-5/#post-11728298)
 * Hey [@magikweb](https://wordpress.org/support/users/magikweb/),
 * Really sorry about the long delay. Life’s been busy.
 * The good news is that I’ve found the problem and I’m going to add a feature in
   that will handle the work for you.
 * It’s not an issue with the plugin. Basically external domains are blocked by 
   WordPress by default.
 * Can you confirm you’re still interested in this feature and I’ll prioritise getting
   it into the plugin.
 * Thanks for your patience,
 * Tom
 *  Thread Starter [Vincent Poirier](https://wordpress.org/support/users/magikweb/)
 * (@magikweb)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/redirection-after-login-5/#post-11728494)
 * Hello Tom,
    Yeah, it’s not critical for our project, but we’d definitely use 
   that feature instead of applying a bunch of workarounds. 🙂
 *  Plugin Author [tbenyon](https://wordpress.org/support/users/tbenyon/)
 * (@tbenyon)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/redirection-after-login-5/#post-11728680)
 * Cool. I’ll try and get it deployed this weekend.
 * Feel free to chase me 😊
 *  Plugin Author [tbenyon](https://wordpress.org/support/users/tbenyon/)
 * (@tbenyon)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/redirection-after-login-5/#post-11734157)
 * Hey [@magikweb](https://wordpress.org/support/users/magikweb/),
 * This update is now deployed – let me know if this works for you.
 * If it’s looking good your end, I’d be grateful if you could write a [review](https://wordpress.org/plugins/external-login/#reviews)
   or [buy me a beer](https://www.paypal.me/tombenyon) 🙂
 * Thanks,
 * Tom
 * 🙂
 *  Thread Starter [Vincent Poirier](https://wordpress.org/support/users/magikweb/)
 * (@magikweb)
 * [6 years, 11 months ago](https://wordpress.org/support/topic/redirection-after-login-5/#post-11755465)
 * Awesome, I’ll give it a shot within a few weeks.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Redirection after login’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/external-login_fbebd6.svg)
 * [External Login](https://wordpress.org/plugins/external-login/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/external-login/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/external-login/)
 * [Active Topics](https://wordpress.org/support/plugin/external-login/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/external-login/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/external-login/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Vincent Poirier](https://wordpress.org/support/users/magikweb/)
 * Last activity: [6 years, 11 months ago](https://wordpress.org/support/topic/redirection-after-login-5/#post-11755465)
 * Status: resolved