Support » Plugin: Login Widget With Shortcode » login_redirect filter

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author


    Please use lwws_login_redirect filter if you want to customize after login redirection using this plugin.

    Thank you.

    The best solution turned out to be to add the following code into the wp_login add_action

    // check Login Sidebar Widget plugin is active
    if (is_plugin_active('login-sidebar-widget/login.php'))
        add_filter('lwws_login_redirect', array(&$this, "redirectLogin"), 10, 2);

    Where redirectLogin looks like:

    public function redirectLogin($redirect_to, $userID) 
       $user_meta = get_userdata($userID);
       /* add code to determine where to redirect to */
       return $newURL;

    I tried adding the filter on the plugins_loaded action, but it was too early

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘login_redirect filter’ is closed to new replies.