[Mediawiki-l] Custom namespaces and discussion pages

Snowolf snowolf at snowolf.eu
Sun May 27 23:50:19 UTC 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi all,

I've created some custom namespaced on one of my wikis, Botwiki
(previously known as pywikipedia).

I've put these lines in my LocalSettings.php file:

- ---

#Custom namespaces
$wgExtraNamespaces =
    array(100 => "Manual",
          101 => "Manual talk",
          102 => "Python",
          103 => "Python talk",
          104 => "Php",
		  105 => "Php talk",
		  106 => "Perl",
		  107 => "Perl talk",
		  108 => "AWB",
		  109 => "AWB talk",
		  110 => "IRC",
		  111 => "IRC talk",
		  112 => "Other",
		  113 => "Other talk"
          );
$wgContentNamespaces[] = 100;
$wgContentNamespaces[] = 102;
$wgContentNamespaces[] = 104;
$wgContentNamespaces[] = 106;
$wgContentNamespaces[] = 108;
$wgContentNamespaces[] = 110;
$wgContentNamespaces[] = 112;

- ---

However, I have a big problem: when I go to a page in one of these new
namespaces (not the discussion, the main ones), for example
http://botwiki.sno.cc/wiki/Perl:Copyright_Violation_Bot , I found the
red link to the discussion page. It's right, as there is no discussion
page for that article. But if you click on it, it brings you to
http://botwiki.sno.cc/w/index.php?title=Perl_talk:Copyright_Violation_Bot&action=edit
correct, of course. But have a look of the article and discussion tabs:
they are both red! The first, "article", leads to
http://botwiki.sno.cc/w/index.php?title=Perl_talk:Copyright_Violation_Bot&action=edit
when it should lead to
http://botwiki.sno.cc/wiki/Perl:Copyright_Violation_Bot and the second,
"discussion", leads to
http://botwiki.sno.cc/w/index.php?title=Talk:Perl_talk:Copyright_Violation_Bot&action=edit
, when it should lead to
http://botwiki.sno.cc/w/index.php?title=Perl_talk:Copyright_Violation_Bot&action=edit
.

It's the first time I deal with custom namespaces :-( but I have some
ideas of what it can be. Can the problem be with the
$wgContentNamespaces settings? So it detects everything as ns0? (don't
think so).

Or can it be the fact that I haven't used an underscore in the
$wgExtraNamespaces definition?

Snowolf


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGWhk7sdafW5NQMtERAuX+AKDQ7QLNjXv9cu+ZbSLXidMzgi/vNgCaA7VT
+VTgR3iI/BI7FVDqcyRZVJ0=
=a4yP
-----END PGP SIGNATURE-----



More information about the MediaWiki-l mailing list