From: Brion Vibber Date: Tue, 17 Feb 2009 22:51:19 +0000 (+0000) Subject: Follow-up to r47217 "Add a tag on redirected page views per... X-Git-Tag: 1.31.0-rc.0~42837 X-Git-Url: http://git.cyclocoop.org/url?a=commitdiff_plain;h=8d9243cf3;p=lhc%2Fweb%2Fwiklou.git Follow-up to r47217 "Add a tag on redirected page views per googlewebmastercentral.blogspot.com/2009/02/specify-your-canonical.html" We can use a relative link in the HTML here and save a few bytes of output; consumer is required to be able to expand relative links it finds here. --- diff --git a/includes/Article.php b/includes/Article.php index e3c57066b1..eeaca044eb 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -839,7 +839,7 @@ class Article { // Add a tag $wgOut->addLink( array( 'rel' => 'canonical', - 'href' => $this->mTitle->getFullURL() ) + 'href' => $this->mTitle->getLocalURL() ) ); $wasRedirected = true; }