HTTP Response Headers: Multiple Link Values

I am working on SEO for a Rails application.

The website is fully localized and I am following this google article to add hreflang alternate page links.

HTML links are <head>fine.

I am having problems with answer headers .

I understand that I have to provide values ​​for each alternate version of the page, but I'm not sure how to set multiple values.

I tried passing them as a comma separated list. Browsers seem to get it right, but since individual values ​​contain half-columns, this doesn't look right.

Is there any link to it? Even a sample web page that is known to implement it correctly will help.

+4
source share
1 answer

I have no experience with this, but according to the examples in the same RFC, they are separated by a comma:

Link: </TheBook/chapter2>;
      rel="previous"; title*=UTF-8'de'letztes%20Kapitel,
      </TheBook/chapter4>;
      rel="next"; title*=UTF-8'de'n%c3%a4chstes%20Kapitel

It is indirectly confirmed by 5.3 (emphasis added):

Note that extension relationship types MUST be absolute URIs in Link headers and MUST be specified if they contain a semicolon (";") or a comma (",") ( since these characters are used as separators in the header itself ).

+8
source

All Articles