Difference between revisions of "Mediawiki File Uploads"
Jump to navigation
Jump to search
PeterHarding (talk | contribs) |
PeterHarding (talk | contribs) |
||
Line 2: | Line 2: | ||
Requires a bit of manual work on the LocalConfig.php file. | Requires a bit of manual work on the LocalConfig.php file. | ||
<pre> | |||
# If PHP's memory limit is very low, some operations may fail. | |||
# ini_set( 'memory_limit', '20M' ); | |||
</pre> | |||
<pre> | |||
session_save_path("d:/Web/htdocs/sessions"); | |||
... | |||
$wgEmergencyContact = "xxx@xxx.com.au"; | |||
$wgPasswordSender = "xxx@xxx.com.au"; | |||
... | |||
## To enable image uploads, make sure the 'images' directory | |||
## is writable, then set this to true: | |||
$wgEnableUploads = true; | |||
$wgFileExtensions = array('png', 'gif', 'jpg', 'jpeg', 'bmp', 'pdf', 'svg', 'svgz','zip', 'csv', 'pl', 'py', 'doc', 'xls', 'ppt', 'pps', 'xml'); | |||
$wgMaxUploadSize = 999999999; | |||
... | |||
#settings for fileLinkExtension | |||
$wgFilelinkExtensionPath = "extensions/FileLinkExtension"; | |||
include("$IP/$wgFilelinkExtensionPath/FileLinkExtension.php"); | |||
#end settings for fileLinkExtension | |||
$wgUrlProtocols = array( | |||
'http://', | |||
'https://', | |||
'ftp://', | |||
'file://', | |||
'irc://', | |||
'gopher://', | |||
'telnet://', // Well if we're going to support the above.. -ævar | |||
'nntp://', // @bug 3808 RFC 1738 | |||
'worldwind://', | |||
'mailto:', | |||
'news:' | |||
); | |||
... | |||
# Allow HTML in wiki pages | |||
$wgUserHtml=true; | |||
... | |||
</pre> | |||
<pre> | |||
</pre> | |||
<pre> | |||
</pre> | |||
=Links= | |||
Check oput the following links: | Check oput the following links: | ||
* http://www.mediawiki.org/wiki/Manual:Mime_type_detection | * http://www.mediawiki.org/wiki/Manual:Mime_type_detection | ||
[[Category:Mediawiki]] | [[Category:Mediawiki]] |
Revision as of 09:09, 5 March 2008
Enabling FIle Uploads into a Mediawiki Site
Requires a bit of manual work on the LocalConfig.php file.
# If PHP's memory limit is very low, some operations may fail. # ini_set( 'memory_limit', '20M' );
session_save_path("d:/Web/htdocs/sessions"); ... $wgEmergencyContact = "xxx@xxx.com.au"; $wgPasswordSender = "xxx@xxx.com.au"; ... ## To enable image uploads, make sure the 'images' directory ## is writable, then set this to true: $wgEnableUploads = true; $wgFileExtensions = array('png', 'gif', 'jpg', 'jpeg', 'bmp', 'pdf', 'svg', 'svgz','zip', 'csv', 'pl', 'py', 'doc', 'xls', 'ppt', 'pps', 'xml'); $wgMaxUploadSize = 999999999; ... #settings for fileLinkExtension $wgFilelinkExtensionPath = "extensions/FileLinkExtension"; include("$IP/$wgFilelinkExtensionPath/FileLinkExtension.php"); #end settings for fileLinkExtension $wgUrlProtocols = array( 'http://', 'https://', 'ftp://', 'file://', 'irc://', 'gopher://', 'telnet://', // Well if we're going to support the above.. -ævar 'nntp://', // @bug 3808 RFC 1738 'worldwind://', 'mailto:', 'news:' ); ... # Allow HTML in wiki pages $wgUserHtml=true; ...
Links
Check oput the following links: