Make WordPress Core

Opened 5 years ago

Last modified 5 years ago

#23443 closed enhancement

Change in behaviour of 'wp_signup_location' filter since WordPress 3.5 — at Version 2

Reported by: Cimmo Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.5.1
Component: Multisite Keywords: reporter-feedback
Focuses: Cc:

Description (last modified by ocean90)

Plug-in's author epic: My plug-in used to attach to the filter 'wp_signup_location' to add a parameter like '?blog_id=7', this to remember where the user clicked 'Register' from. In example from:




Behaviour in WordPress 3.4 MS and earlier: My plug-in successfully modified the signup location adding the parameter needed.

  1. wp-login.php redirects to the filtered url
  2. wp-signup.php checks if it !is_main_site(), but till 3.4 not passing any parameter to is_main_site was basically always returning true, and !true always false.

Behaviour in WordPress 3.5 MS and later:

  1. wp-login.php redirects to the filtered url
  2. wp-signup.php checks if it !is_main_site(), this returns true (it is not) and then passes and then redirect once more using network_site_url
  3. network_site_url seems removing any parameter added, jeopardizing my filter added earlier.

The exact patch that changed this (correctly probably) is this one: http://core.trac.wordpress.org/attachment/ticket/22090/22090.diff

My question is: now, how can have my added parameter not filtered out?

thank you Marco

Change History (2)

#1 @Cimmo
5 years ago

Oh I got it, the problem is not adding *any* parameter, the problem is adding exactly 'blog_id' parameter that fools is_main_site(), so a possible fix is to change to another name.

And I guess even this ticket will be closed as by design.

#2 @ocean90
5 years ago

  • Description modified (diff)
  • Keywords reporter-feedback added

Can you provide a link to your plugin or the part which hooks into wp_signup_location?

Note: See TracTickets for help on using tickets.