Hi,
I am trying to set up a wiki family with subdirectories based on mediawiki 1.18.1 version ie.,
http://mysite.com/wiki1 and http://mysite.com/wiki2
I am referring to the drupal-style settings documentation for the above wiki family setup. The problem is even with the drupal-style LocalSettings.php (which looks for a regular mediawiki-style LocalSettings.php in the sites directory) in place, going to http://mysite.com/wiki1 brings me up with the installer to generate a LocalSettings.php.
Following the same drupal-style instructions, I was able to set up a wiki family (subdirectories as above) successfully with mediawiki-1.16.1 version. I realize that there are many changes since 1.161.1, in particular the $IP variable settings and require_once("includes/DefaultSettings.php") were moved to includes/WebStart.php from LocalSettings.php. Also new to 1.18.1 is the HipHop compiler/interpreter. The paths in includes/WebStart.php are either compiled/interpreted paths set by the hiphop library "includes/Init.php".
I tried to modify the "includes/WebStart.php" in the old style, by changing "MWInit::interpretedPath("LocalSettings.php") to "($IP/LocalSettings.php"), but still I am being presented with the installer going to http://mysite.com/wiki1
Would you point to me how and where I should make changes to create a wiki family with the 1.18.1 code base? Any help is greatly appreciated.
Thanks, Poornima.
On Fri, 02 Mar 2012 09:56:19 -0800, Poornima Pochana ppreddy@uab.edu wrote:
Hi,
I am trying to set up a wiki family with subdirectories based on mediawiki 1.18.1 version ie.,
http://mysite.com/wiki1 and http://mysite.com/wiki2
I am referring to the drupal-style settings documentation for the above wiki family setup. The problem is even with the drupal-style LocalSettings.php (which looks for a regular mediawiki-style LocalSettings.php in the sites directory) in place, going to http://mysite.com/wiki1 brings me up with the installer to generate a LocalSettings.php.
Following the same drupal-style instructions, I was able to set up a wiki family (subdirectories as above) successfully with mediawiki-1.16.1 version. I realize that there are many changes since 1.161.1, in particular the $IP variable settings and require_once("includes/DefaultSettings.php") were moved to includes/WebStart.php from LocalSettings.php. Also new to 1.18.1 is the HipHop compiler/interpreter. The paths in includes/WebStart.php are either compiled/interpreted paths set by the hiphop library "includes/Init.php".
I tried to modify the "includes/WebStart.php" in the old style, by changing "MWInit::interpretedPath("LocalSettings.php") to "($IP/LocalSettings.php"), but still I am being presented with the installer going to http://mysite.com/wiki1
Would you point to me how and where I should make changes to create a wiki family with the 1.18.1 code base? Any help is greatly appreciated.
Thanks, Poornima.
You should not be modifying core code to make wiki families.
You do that by adding conditionals into your LocalSettings.php and setting configuration variables with different settings depending on where you are.
Thank you Daniel.
Would the configuration variables happen to be 'MW_CONFIG_FILE' , '$IP'? Can you provide an example how to set this conditional? Sorry, I haven't hacked into mediawiki code much, so am quite a novice here.
Poornima.
On Mar 2, 2012, at 1:21 PM, Daniel Friesen wrote:
You should not be modifying core code to make wiki families.
You do that by adding conditionals into your LocalSettings.php and setting configuration variables with different settings depending on where you are.
-- ~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://daniel.friesen.name]
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
No, neither of those should be touched. MW_CONFIG_FILE can't be changed from within LocalSettings.php and $IP is the path to where the code is, that should be left alone.
Variables like $wgServer, $wgDBname, etc... are what you would change. For example:
if ( $_SERVER['HTTP_HOST'] == 'a.example.com' ) { $wgServer = "http://a.example.com"; $wgDBname = "awiki"; } elseif ( $_SERVER['HTTP_HOST'] == 'b.example.com' ) { $wgServer = "http://b.example.com"; $wgDBname = "bwiki"; }
You use conditionals to set the variables that would actually be different between the installations.
"PP" == Poornima Pochana ppreddy@uab.edu writes:
PP> Would you point to me how and where I should make changes to create a wiki family
mediawiki-l@lists.wikimedia.org