[Mediawiki-l] Multiple wikis using same directory

Mauro do Carmo mauro at carmo.info
Sun Oct 29 20:15:53 UTC 2006

Thanks Zarrabeitia,

So, if I understand this configuration allows us to use one folder with two different databases according to the url the user enter,
right? My question is: 

1) What is the advantage for this configuration?  
2) What configuration the wikipedia uses for the different address it has?

I am up to lunch my English version of my site, so I was wondering what would be the most appropriate approach. I was thinking in

www.my_site.info    ==> Database      ==>site.info folder
www.en.my_site.info ==> Database_en   ==>em.site.info folder  

Thanks a lot, mauro.
Server: MediaWiki: 1.6.8
        PHP: 4.3.11 (apache)
        MySQL: 4.1.20-max-log
        phpMyAdmin -

       Win XP Home Edition SP2
       Browser Mozila FireFox

|-----Original Message-----
|From: mediawiki-l-bounces at Wikimedia.org [mailto:mediawiki-l-bounces at Wikimedia.org] On Behalf Of Luis
|Sent: Friday, October 27, 2006 9:40 AM
|To: MediaWiki announcements and site admin list
|Subject: Re: [Mediawiki-l] Multiple wikis using same directory
|I hope you are not referring to my message "Mediawiki as a CMS." (I mean, what
|I did there was a hack, and though it worked for my (en|es).wikipedia mirror,
|I wouldn't exactly recommend it).
|Still, if you are referring to my hack, here it is:
|I installed a mediawiki in, for instance,
|and pointed the en.wikipedia and the es.wikipedia virtualhosts to that folder.
|On my localsettings.php,
|if ($_SERVER["HTTP_HOST"]=="es.wikipedia.uh.cu")
|        $db_lang="es";
|if ($_SERVER["HTTP_HOST"]=="en.wikipedia.uh.cu")
|        $db_lang="en";
|$wgDBserver         = "";
|$wgDBname           = "wiki";
|$wgDBuser           = "wikipedia";
|$wgDBpassword       = "wikipedia";
|$wgDBprefix         = $db_lang;
|$wgDBtype           = "mysql";
|$wgDBport           = "5432";
|$wgLanguageCode = $db_lang;
|And that seems to work. (the ifs and the $db_lang variable were added by me).
|There are some problems with the maintenance scripts in this setup (they
|obviously don't define the _SERVER variable so they don't load the
|configuration properly so I have to work around that)
|But given my 0 expertise with mediawiki, I'm sure there is a better way to do
|it :D
|On Friday 27 October 2006 05:48, Robert Leverington wrote:
|> Someone on here was talking about how to run multiple wikis using the
|> same wiki directory, I have a vague idea of how this could be done
|> (using a index.php file with exactly the same contents but with a
|> different name). But I don't know how I could set up the local
|> settings file. When the person said about it I think he used an if
|> statement but I don't know how to form one of those which has more
|> than two possibilities.
|> Thanks,
|Luis Zarrabeitia
|Fac. de Matemática y Computación, UH.
|MediaWiki-l mailing list
|MediaWiki-l at Wikimedia.org
|No virus found in this incoming message.
|Checked by AVG Free Edition.
|Version: 7.1.408 / Virus Database: 268.13.13/500 - Release Date: 10/26/2006

No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.408 / Virus Database: 268.13.17/505 - Release Date: 10/27/2006

More information about the MediaWiki-l mailing list