On Mon, Oct 4, 2010 at 4:42 AM, Alex Brollo <[email protected]> wrote:
> It's strange (but I guess that there's a sound reason) that plain wikilinks
> point to a variable field of wiki records (the name of the page) while many
> troubles would be solved, if they could point to the invariable field of
> such records: the id. The obviuos restult is, that all links are broken (and
> need fixing) as soon as a page is "moved" (t.i. renamed).
>
> My question is: which is the sound reason for this strange thing? There's
> some idea about fixing this?

1) Links to nonexistent pages (which don't yet have an id) are permitted.

2) Sometimes you have the names of specific topics redirecting to
general topics.  E.g., on a small wiki, [[Grizzly bear]] might
redirect to [[Bear]].  When I type [[Grizzly bear]], I mean to link to
the article about grizzly bears.  Although that's currently part of
the article about bears, that might stop being the case.  If someone
changes [[Grizzly bear]] from a redirect into its own article, I want
all links to now point to the new article, not the thing it used to
redirect to.

3) When you follow a redirect, we need to display the "redirected
from" message, so that editors can notice and easily reach and change
the redirect if necessary.  That means that we need to use a different
URL for accessing articles through redirects vs. accessing it directly
-- we don't *want* the two concepts to be treated as equivalent,
because redirects become hard to edit.

On the other hand, what exactly are the problems that your suggestion
is meant to solve?

On Mon, Oct 4, 2010 at 5:27 AM, Alex Brollo <[email protected]> wrote:
> :-)  Yes, they just exist  for that...  but in my view of "layman database
> manager"  I learn by experience  a rule of relational databases: NEVER  link
> to variable  fields of a table! Always link to id!

There are two separate concepts here: "the article called [[Bear]]"
(identified by title, or actually namespace+title), and "the article
with the text and history that currently resides under the name
[[Bear]]" (identified by id).  When we want to refer to an article by
a particular name, whatever its current contents, we use
namespace+title; when we want to refer to a particular text and
history, whatever its current name, we use id.  If you look at the
MediaWiki schema, you'll find that there are lots of places where we
do both.

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to