WordPress.org

Make WordPress Core

Opened 4 years ago

Closed 4 years ago

#11700 closed enhancement (fixed)

Improvements to redirect_canonical()

Reported by: jfriedl Owned by: markjaquith
Milestone: 3.0 Priority: normal
Severity: normal Version: 2.8
Component: Canonical Keywords: has-patch reporter-feedback
Focuses: Cc:

Description

Don't compare port numbers for the default port (80). Don't run the 'redirect_canonical' hook when $redirect_url is empty.

Attachments (1)

11700.patch (796 bytes) - added by azaozz 4 years ago.

Download all attachments as: .zip

Change History (6)

azaozz4 years ago

comment:1 azaozz4 years ago

Patch by jfriedl.

comment:2 scribu4 years ago

  • Keywords has-patch added
  • Milestone set to 3.0

comment:3 westi4 years ago

  • Keywords reporter-feedback added

What are the bugs this patch fixes?
How can we reproduce them?

comment:4 markjaquith4 years ago

Putting in the second part, because it's just good error avoidance. I don't understand why you want to ignore port 80. http://example.com:80/ is not the same URL as http://example.com/ Re-open with a better description of the port issue and why your fix is correct.

comment:5 markjaquith4 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [12692]) Do not fire the redirect_canonical filter if the redirect_url is empty. fixes #11700

Note: See TracTickets for help on using tickets.