Created
February 9, 2012 23:33
-
-
Save perusio/1784254 to your computer and use it in GitHub Desktop.
Nginx support for rel="canonical" HTTP headers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## As explained here: http://googlewebmastercentral.blogspot.com/2011/06/supporting-relcanonical-http-headers.html | |
## This is the add_header incantation to make it work. | |
add_header Link "<$scheme://$http_host$request_uri>; rel=\"canonical\""; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you. This saved a lot of time work.