Pro Sites 3.5.2 - Wrong Admin URL after Site Registration

After a user registers a subsite, the Pro Sites plugin incorrectly supplies the mainsite admin url, instead of proper subsite admin url, for the user to login to their dashboard.

This can be fixed by editing line 628 of /pro-sites/pro-sites-files/lib/ProSites/View/Front/Gateway.php and changing it:

from (current, broken):

$blog_id = ! empty( $upgrade_blog_id ) ? $upgrade_blog_id : ! empty( $new_blog_id ) ? $new_blog_id : ! empty( $new_blog_name ) ? get_id_from_blogname( $new_blog_name ) : 0;

to (new, fixed):

$blog_id = ! empty( $upgrade_blog_id ) ? $upgrade_blog_id : (! empty( $new_blog_id ) ? $new_blog_id : (! empty( $new_blog_name ) ? get_id_from_blogname( $new_blog_name ) : 0));

Please update plugin. Thank you.

  • Adam Czajczyk

    Hello u,

    I hope you're well today and thank you for your post!

    Your suggestion is of great value to us. However, it would be great if you could provide me with some more details. As you already suggested a solution, I'm still not sure what's exact nature of the issue :slight_smile:

    What is an URL that's provided by Pro Sites and why is it wrong? Could you please elaborate a bit on this? Let me also know about other plugins (such as e.g. Domain Mapping or similar) that may possibly affect that URL.

    I'm asking this only because testing this on my own sandbox I wasn't able to find any errors there.

    Please advise!
    Best regards,
    Adam

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.