diff --git a/admin_manual/configuration_mimetypes/index.rst b/admin_manual/configuration_mimetypes/index.rst index 6fe17e51d..fbe509349 100644 --- a/admin_manual/configuration_mimetypes/index.rst +++ b/admin_manual/configuration_mimetypes/index.rst @@ -9,3 +9,11 @@ Mimetypes Management mimetype_aliases mimetype_mapping +Icon retrieval +-------------- + +When an icon is retrieved for a mimetype, if the full mimetype cannot be found, +the search will fallback to looking for the part before the slash. Given a file +with the mimetype 'image/my-custom-image', if no icon exists for the full +mimetype, the icon for 'image' will be used instead. This allows specialised +mimetypes to fallback to generic icons when the relevant icons are unavailable. diff --git a/admin_manual/configuration_mimetypes/mimetype_aliases.rst b/admin_manual/configuration_mimetypes/mimetype_aliases.rst index 134632035..f8c37bf9f 100644 --- a/admin_manual/configuration_mimetypes/mimetype_aliases.rst +++ b/admin_manual/configuration_mimetypes/mimetype_aliases.rst @@ -6,17 +6,43 @@ possible to show more specific icons for certain mimetypes. Take as an example audio files. It is nicer if they show a nice audio icon instead of the default file icon. -By default ownCloud comes with ``mimetypealiases.dist.json``. This is a -simple json array. -Administrators should not update this file as it will get replaced on upgrades -of ownCloud. Instead the file ``mimetypealiases.json`` should be created and -modified, this file has precedence over the shipped file. +By default ownCloud is distributed with ``config/mimetypealiases.dist.json``. +Administrators should not modify this file, as it will be replaced when +ownCloud is updated. -Updating mimetype aliases -------------------------- -If there is a custom ``mimetypealiases.json`` and that is edited or ownCloud is -updated you should run:: +Adding custom aliases +--------------------- + +Custom mimetype aliases can be added to ``config/mimetypealiases.json``, using +the same syntax as ``config/mimetypealiases.dist.json``. Some common mimetypes +that may be useful in creating aliases are: + +image + Generic image + +image/vector + Vector image + +audio + Generic audio file + +x-office/document + Word processed document + +x-office/spreadsheet + Spreadsheet + +x-office/presentation + Presentation + +text + Generic text document + +text/code + Source code + +Once you have made changes to ``config/mimetypealiases.json``, run the +following to propogate the changes through the system:: $ ./occ maintenance:mimetypesjs -This commands makes sure that the changes are propagate through the system.