빈 파일은 올라가지 않음.
vim /etc/php/7.4/apache2/php.ini
file_uploads = On
upload_max_filesize = 2048M
cd /var/www/html/mediawiki
sudo chown -R www-data:www-data images/
sudo chmod -R 755 images
vim LocalSettings.php
$wgFileBlacklist = [
'exe', 'scr', 'dll', 'msi', 'vbs', 'bat', 'com', 'pif', 'cmd', 'vxd', 'cpl',
];
$wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'doc',
'xls', 'mpp', 'pdf', 'ppt', 'tiff', 'bmp', 'docx', 'xlsx',
'pptx', 'ps', 'odt', 'ods', 'odp', 'odg', 'zip', 'gz'
);
$wgStrictFileExtensions = false;
$wgTrustedMediaFormats[] = 'application/zip';
$wgAllowJavaUploads = true;
cd images
sudo vim .htaccess
<IfModule rewrite_module>
RewriteEngine On
RewriteOptions inherit
RewriteCond %{QUERY_STRING} \.[^\\/:*?\x22<>|%]+(#|\?|$) [nocase]
RewriteRule . - [forbidden]
# Fix for bug T64289
Options +FollowSymLinks
</IfModule>
댓글 없음:
댓글 쓰기