Tuesday, June 23, 2009

wikimedia setup

Wiki media configuration tips:

Edit LocalSetting.php

How to setup only logged in user can edit / add post:

//only logged in user can edit
$wgGroupPermissions['*']['edit'] = false;
How to setup only admin can add user:
//only admin can create account...
$wgGroupPermissions['*']['createaccount'] = false;
How to enable upload for wiki media?
//find for $wgEnableUploads
$wgEnableUploads = true;
How to allow upload of other files:

$wgFileExtensions[] = "zip";
$wgFileExtensions[] = "gz";
$wgFileExtensions[] = "pdf";
$wgFileExtensions[] = "doc";
$wgFileExtensions[] = "xls";
$wgFileExtensions[] = "ppt";

But, upload will fail if you enable imagemagick, because it assume all your is image. Therefor, we will need to disable imagemagick:

$wgUseImageMagick = false;

Hope it helps ;)

Reference:
http://www.mediawiki.org/wiki/Configuring_file_uploads#Upload_permissions

No comments: