Index: trunk/phase3/includes/Wiki.php |
— | — | @@ -192,7 +192,8 @@ |
193 | 193 | } |
194 | 194 | /* Check for a redirect loop */ |
195 | 195 | if( !preg_match( '/^' . preg_quote( $this->getVal('Server'), '/' ) . '/', $url ) && $title->isLocal() ) { |
196 | | - $output->redirect( $url ); |
| 196 | + // 301 so google et al report the target as the actual url. |
| 197 | + $output->redirect( $url, 301 ); |
197 | 198 | } else { |
198 | 199 | $title = SpecialPage::getTitleFor( 'Badtitle' ); |
199 | 200 | $output->setTitle( $title ); // bug 21456 |
Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -5320,7 +5320,9 @@ |
5321 | 5321 | |
5322 | 5322 | /** |
5323 | 5323 | * Disable redirects to special pages and interwiki redirects, which use a 302 |
5324 | | - * and have no "redirected from" link. |
| 5324 | + * and have no "redirected from" link. Note this is only for articles with #Redirect |
| 5325 | + * in them. URL's containing a local interwiki prefix (or a non-canonical special |
| 5326 | + * page name) are still hard redirected regardless of this setting. |
5325 | 5327 | */ |
5326 | 5328 | $wgDisableHardRedirects = false; |
5327 | 5329 | |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -203,6 +203,8 @@ |
204 | 204 | page restrictions |
205 | 205 | * Make truncate function automatically consider length of '...' string, |
206 | 206 | since length can vary by localization. |
| 207 | +* (bug 28242) Make redirects generated by urls containing a local interwiki |
| 208 | + prefix be a 301 instead of a 302. |
207 | 209 | |
208 | 210 | === API changes in 1.18 === |
209 | 211 | * (bug 26339) Throw warning when truncating an overlarge API result |