Author Topic: mime types  (Read 5179 times)

Offline guidovanharten

  • Jr. Member
  • **
  • Posts: 13
mime types
« on: March 12, 2015, 05:57:59 PM »
While configuring Roundcube, the Roundcube Webmail Installer has one item with "NOT OK"

Mimetype to file extension mapping:  NOT OK
Please set a valid path to your webserver's mime.types file to the mime_types config option.
If you can't find such a file, download it from svn.apache.org.

I downloaded that file, but where do I it upload to?

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,493
    • http://SKaero.com/
Re: mime types
« Reply #1 on: March 12, 2015, 06:37:29 PM »
You can upload it to the Roundcube directory.

Offline guidovanharten

  • Jr. Member
  • **
  • Posts: 13
Re: mime types
« Reply #2 on: March 13, 2015, 04:19:24 AM »
I uploaded it to the main directory of my roundcube installation http://guido.vanharten.net/rc-mime.JPG, but still the same error.
Is the chosen directory the right one, or do I have to place it into a subdirectory (which?)?

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,493
    • http://SKaero.com/
Re: mime types
« Reply #3 on: March 13, 2015, 07:02:54 AM »
You also need to set the absolute path to the file in the Roundcube config.inc.php
Code: [Select]
// Absolute path to a local mime.types mapping table file.
// This is used to derive mime-types from the filename extension or vice versa.
// Such a file is usually part of the apache webserver. If you don't find a file named mime.types on your system,
// download it from http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types
$config['mime_types'] = null;

Offline guidovanharten

  • Jr. Member
  • **
  • Posts: 13
Re: mime types
« Reply #4 on: March 13, 2015, 08:17:33 AM »
I am sorry, in my file config.inc.php (in the directory config) I can't find this section. In the directory config I see more files: config.inc.php, defaults.inc.php, mimetypes.php and config.inc.php.sample.
The file mimetypes.php starts with
Code: [Select]
<?php

/**
 * Local mapping file to specify mime-types based on common file-name extensions
 *
 * Please note that this mapping takes precedence over the content-based mime-type detection
 * and should only contain mappings which cannot be detected properly from the file contents.
 */

return array(
  
'xls' => 'application/vnd.ms-excel',
  
'xlm' => 'application/vnd.ms-excel',
  
'xla' => 'application/vnd.ms-excel',
(and many more lines)

What do I have to do?

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,493
    • http://SKaero.com/
Re: mime types
« Reply #5 on: March 13, 2015, 09:06:15 AM »
You need the section to the config.inc.php to change the setting.

Offline guidovanharten

  • Jr. Member
  • **
  • Posts: 13
Re: mime types
« Reply #6 on: March 13, 2015, 10:40:34 AM »
Because these section is not found into config.inc.php, I add it into that file.
After that I repeat .../installer/index.php?_step=3, but still I get the same error.
Hope anyone can help me...

Offline guidovanharten

  • Jr. Member
  • **
  • Posts: 13
Re: mime types
« Reply #7 on: March 18, 2015, 04:33:02 AM »
Finally the helpdesk of my webhosting provider helped me.
I needed to know what to fill in for the exact absolute path of mime.types.
$config['mime_types'] = "/home/(my username)/domains/(my domain)/public_html/(my subdomain)/config/mime.types";
Just the start of this address I didn't know.

Thanks to all who helped me!