[This message has been crossposted from <intlwiki-L> to <wikitech-L>. Replies should go only to <wikitech-L>.]
Timwi wrote in part:
In addition to this, however, I would like to point out that it is widely considered a bad practice to serve the same content under several URLs. Currently I can reach the exact same article by going to any of a veritable plethora of URLs:
http://www.wikipedia.org/w/wiki.phtml?title=Dextrose http://www.wikipedia.org/w/wiki.phtml?title=Glucose http://www.wikipedia.org/wiki/Dextrose http://www.wikipedia.org/wiki/Glucose http://www.wikipedia.org/w/wiki.phtml?search=dextrose&go=Go http://www.wikipedia.org/w/wiki.phtml?search=glucose&go=Go
plus several different capitalisations of the latter two. Those latter two I find particularly disturbing. People will link to them and trigger the Search algorithm for every visitor, which generates an unnecessary impact on the database server. Plus, the searches may not return the same article indefinitely.
I think that we want to consider the purpose of the differences. You've already mentioned the purpose of "Dextrose"/"Glucose"; it's to give us the redirection information. So that's OK. I see no purpose to the "search" URIs, so I agree that they should redirect; and in addition to your point about activating the search algorithm, also note that the algorithm might not even give the same page next time! (Don't confuse the two sorts of redirection here: Wikipedia redirection and HTTP redirection. I just mentioned both of these in that order.) Another URI variation that you just barely missed is capitalisation among the /non/-search URIs -- this serves no purpose under our page capitalisation scheme, so they should probably redirect to capitalised URIs too.
Then there's the difference between "/w/wiki.phtml?title=" and "/wiki/". AFAICT, the only purpose of this is to have robots index "/wiki/" URIs, since "/w/" URIs are set to be unindexed in our <robots.txt> file. (Those that understand these things will hopefully confirm if I'm right.) Then I agree with your solution; "/w/wiki.phtml?title=..." should redirect to "/wiki/..." if no ampersands appear in the ellipsis -- and this could conceivably even increase robots' indexing of our pages.
-- Toby
wikitech-l@lists.wikimedia.org