• Resolved FolioVision

    (@foliovision)


    Hello,

    we use [wppb-register] on a multisite which also uses WordPress MU Domain Mapping plugin. Once the user verifies the account via email, he gets back to the registration page where he gets the login form.

    However the login form redirects to a bad place.

    I figured out the form uses some field to remember the URL where the user should be put after loggin in. It uses wppb_curpageurl() to determine the page address.

    However that function uses $_SERVER variables which don’t match if you are using domain mapping. Why not use home_url()?

    Here’s my proposed fix which takes care of these issues:

    function wppb_curpageurl() {
      $pageURL = home_url($_SERVER["REQUEST_URI"]);
      
      if ( function_exists('apply_filters') ) $pageURL = apply_filters('wppb_curpageurl', $pageURL);
    
      return $pageURL;
    }

    With that function it works for us.

    Thanks!

Viewing 1 replies (of 1 total)
  • Plugin Author Georgian Cocora

    (@raster02)

    Hello there,

    We have caught up on this over our support ticketing system, I will let you know over there when our developer has taken a look at the code and implemented it.

    Best Regards,

Viewing 1 replies (of 1 total)

The topic ‘Bad login redirection on WP Multisite with domain mapping’ is closed to new replies.