← Back to Upcase

The Content-Location header

(George Brocklehurst) #1

For a few weeks a group of us at thoughtbot have been getting together to read through RFC 7231 which is part of the updated HTTP/1.1 spec. Last week we got to § 3.1.4 and the Content-Location header.

It’s a pretty dense section of the spec, and we didn’t quite get to the bottom of it, but we’ll be discussing it again this week!

In the meantime … what’s the Content-Location header for?

/cc @mikeburns @calleerlandsson @joannecheng @DeviousDuck

(George Brocklehurst) #2

One thing that was causing confusion was this test page from the W3C, which seems to suggest that Content-Location should impact the base URI of a page: http://jigsaw.w3.org/HTTP/CL/

This is one of the few semantic changes between RFC 2616 and RFC 7231. According to Appendix B:

The definition of Content-Location has been changed to no longer
affect the base URI for resolving relative URI references, due to
poor implementation support and the undesirable effect of potentially
breaking relative links in content-negotiated resources.

The original defintion was in RFC 2616 § 14.14