[Mediawiki-l] Why 'text'=>'mainpage', 'href'=>'mainpage'?

Juanma Barranquero lekktu at gmail.com
Thu Apr 28 01:12:53 UTC 2005


I mean, why isn't it

   array('text'  => 'mainpage', 'href' => 'mainpage-url'),

on $wgNavigationLinks?

I'm asking because I'm doing a dynamic Main Page as a Special:MyProject module.

 - If I set MediaWiki:Mainpage to 'Special:MyProject', the Navigation
menu entry changes to
  'Special:MyProject', which I don't want (I still want the Main Page
to show as "Main Page"
  on the Navigation menu).

 - If I modify $wgNavigationLinks to have

   array('text' => 'mainpage', 'href' => 'mainpage-url'),

  and set MediaWiki:Mainpage-url to 'Special:MyProject', clicking on
the Navigation entry
  brings my Special page, but navigating to http://mylocalhost/wiki
brings me back to
  http://mylocalhost/wiki/Main_Page (as the software has no way to
know that my new
  main page is to be taken from MediaWiki:Mainpage-url)

 - Finally, if I do

   #REDIRECT [[Special:MyProject]]

  on Main_Page, it all works as expected, but the browser's navigation
bar shows
  http://mylocalhost/wiki/Special:MyProject (which is correct but ugly).

So, it'd be nicer if MediaWiki used a MediaWiki:Mainpage for the
navigation menu entry title, and a MediaWiki:Mainpage-url for the
page, and the software knew that the default page comes from
MediaWiki:Mainpage-url.

Or, is there a way to do that already that I'm missing? (as I suspect :)

-- 
                    /L/e/k/t/u



More information about the MediaWiki-l mailing list