A WordPress-centric search engine for devs and theme authors



redirect_canonical ›

Since2.3.0
Deprecatedn/a
apply_filters( 'redirect_canonical', $redirect_url, $requested_url )
Parameters: (2)
  • (string) $redirect_url The redirect URL.
    Required: Yes
  • (string) $requested_url The requested URL.
    Required: Yes
Defined at:
Codex:

Filters the canonical redirect URL.

Returning false to this filter will cancel the redirect.





Source

$redirect_url = apply_filters( 'redirect_canonical', $redirect_url, $requested_url );