WordPress.org

Make WordPress Core

Opened 2 years ago

Last modified 5 months ago

#20226 new enhancement

Don't advertise pingback URL on resources that don't support pingbacks

Reported by: solarissmoke Owned by:
Milestone: Future Release Priority: normal
Severity: minor Version: 3.3
Component: Pings/Trackbacks Keywords:
Focuses: template Cc:

Description

Currently, WordPress indiscriminately adds an X-Pingback header to all responses. Similarly all the bundled themes add link rel="pingback" to all pages.

The purpose of X-Pingback and link rel="pingback" is to advertise that the current resource supports pingbacks and provide a pingback URL. They should only be inserted when the resource actually accepts pingbacks - i.e., only when is_single() is true, and maybe even only when pings are open on that post.

Change History (4)

comment:1 nacin2 years ago

  • Type changed from defect (bug) to enhancement

I could go for a fresh look at this.

add_theme_support( 'automatic-pingback-link' ) could remove rel="pingback" from themes and put it into our hands.

From there, it's a matter of figuring out exactly when to issue the HTTP header and <head> element, and making it extensible.

comment:2 nacin2 years ago

  • Keywords nacin-likes added

comment:3 solarissmoke2 years ago

The rel="pingback" bit looks relatively easy to implement.

The X-Pingback header is not however, because currently headers are sent way before WP has any idea what it is serving. I think this is a bigger issue because it means that things like Last-Modified headers are generic and don't actually reflect the last modified time of the content being served (which sort of defeats the purpose of having them).

comment:4 nacin5 months ago

  • Component changed from Template to Pings/Trackbacks
  • Focuses template added
  • Keywords nacin-likes removed
  • Milestone changed from Awaiting Review to Future Release
Note: See TracTickets for help on using tickets.