Setup mediawiki agar bisa upload gambar/image


Secara default seting mediawiki tidak bisa upload gambar.

Untuk bisa upload gambar perlu disiapkan dengan cara berikut :

  1. Siapkan folder “images” di root public_folder

    mkdir images
    chmod 777 images

  2. Ubah setting di LocalSettings.php

    ## To enable image uploads, make sure the ‘images’ directory
    ## is writable, then set this to true:
    $wgEnableUploads       = true;
    $wgFileExtensions = array( ‘png’, ‘gif’, ‘jpg’, ‘jpeg’, ‘doc’, ‘xls’, ‘pdf’ );
    $wgAllowCopyUploads = true;

Untuk menentukan batasan ukuran file yang boleh diupload dapat diset menggunakan .htaccess atau mengikuti configurasi global di php.ini

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com 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