OK, if we're going to have categories (which I'm basically all in favor
of), I'd like to point out that IMHO it should be a separate table in
the database for these, at least for the links. Look at the mess we
(I;-) made with the language links.
I imagine the following tables
# "categories" : cat_name, cat_id
# "cat_structure" : cat_parent_id, cat_child_id
# "art_in_cat" : article_id, category_id
That means we can have, for example, "Biochemistry" as child of both
"Chemistry" and "Biology", as it should be. That would require several
SQL queries, though, in order to display something like
"Science/Biology/Biochemistry/Proteomics". The alternative would be
# "cat_structure" : category_id, category_full_parent_name
and the parse the category_full_parent_name (e.g.
"Science/Biology/Biochemistry") for "/" in order to display something like
"[[category:science|Science]]/[[category:biology|Biology]]/[[category:Biochemistry|Biochemistry]]/[[category:Proteomics|Proteomics]]"
which will be a lot fater, but probably harder to maintain.
In any case, a Special Page should be used to manage both categories
itself and the articles that belong into them.
*If* we won't have separate tables (for whatever reason), I suggest we
do it like this:
# There's an (editable) category namespace; maybe we won't have to make
it "special" at all, though; I am talking more about an agreement on
that prefix rather than yet another namespace
# On saving an edit to [[category:crap]], all articles linked from there
get "[[category:crap]]" appended to their text, and the appropriate link
set in the linked table.
# On saving an article containing "[[category:crap]]", this article is
appended to the list on that page, if it is not there already.
# All these "edits" could show up on Recent Changes, commited by
"system" or something.
I agree it looks a little patchy (because we don't use a new table!),
but it will be much faster to look up the "what categories does this
page belong to" when displaying it. It will also reduce the display of
the category page to a normal article display.
Magnus