Configuration reference

This document is the index/reference page for all configuration options available in the MCFileManager.

Configuration options

All configuration options are located in a file called "config.php". There are also two example configuration files one "config.php.example" and "config.php.minimal" where the first if a example config and minimal contains the minimum amount of options needed to be modified inorder to get MCFileManager up and running.


Directory specific configuration

MCFileManager has a special access files that can be placed in folders to control/override options. This file is by default named "mc_access" and it may contain any config option as long as it's not left out of the allow_override option.

Place a "_" character infront of option names to only override options in the current directory, so it doesn't get inherited by sub directories.

Example of a mc_access file:

# Excludes some files
filesystem.exclude_file_pattern=/^(\..*)$|^filex$/i

# Only for this level
_filesystem.exclude_directory_pattern=/^somedir$/i

# Restrict max upload file size to 5 MB
upload.maxsize=5MB

Stream MIME types

Files may be streamed or downloaded with the file manager. A specific configuration file for controlling the content types of these HTTP streams are called "mime.types" this file is in the format below HTTP Content type on the left and extensions of the right. The default mime.types file contain most of the files normally used on the web but if any specific file format isn't available in this file you may easily add it by your self.

Example snippet of mime.types file:

application/msword              doc dot
application/pdf                 pdf
application/pgp-signature       pgp
application/postscript          ps ai eps 

File types

File types/extensions are configurable by modifying the lookup table array located in the "file_types.php". This file contains the extension to icon, description and if it's pre viewable or not. By default most of the normally used files are included in this file and if a extension isn't located within this file a "unknown file" icon will be displayed instead. But if you want to get rid of this icon for a specific file extension you could add your own line to this file.