MediaWiki – Setup Upload and Download of Files

This is going to be a short post on how to setup MediaWiki so that you can upload and download files. I’ve only allowed a few file extensions at the moment in the following, but you can add you own if you wish.

At the end of the LocalSettings.php file in the MediaWiki folder (folder containing your MediaWiki app files!) add the following to the END of the file.

$wgFileExtensions =  array('pdf', 'png','jpg','jpeg');
$wgEnableUploads = true;

The first line specifies what file extensions MediaWiki should allow the users to upload.

The second line specifies that uploads should actually be enabled. (Note: This setting is set to false earlier in the file. Thus we put both lines at the end of the file!)


Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: