ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Error when attempting to upload .csv file

February 25, 2012 4:07am

Subscribe [2]
  • #1 / Feb 25, 2012 4:07am

    Jonathan Morgan

    51 posts

    I’ve created a File Upload location that is set to accept “All” file types. Permissions are set to 777.
    When I try and upload a .csv I’m told:

    The filetype you are attempting to upload is not allowed.

    Is there a way around this? Has anyone else had this issue?

    Once I can upload a CSV I’m hoping to use Nicolas Bottari’s CSV to Table plugin, however for now this issue purely involves EE’s core functionality.

    Many thanks in advance for your help!

    Jonathan

  • #2 / Feb 25, 2012 6:38pm

    Sean C. Smith

    3818 posts

    Hi Jonathan Morgan,

    I am sorry to hear you are running into this problem. You should be able to upload csv files. Please open this file /system/expressionengine/config/mimes.php and see if the mime type for csv is there. On my 2.4 install that is on line 49.

    If it’s not there please add this and try again:

    'csv' => array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel'),

    Sean

  • #3 / Feb 26, 2012 4:29pm

    Jonathan Morgan

    51 posts

    Hi Sean,

    Thanks for your response. I’ve just checked mimes.php, and sure enough, on line 49 is:

    'csv' => array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel'),
  • #4 / Feb 27, 2012 9:41am

    Jonathan Morgan

    51 posts

    After sending my last response, I went into my file upload settings and noticed that the folder I was trying to use was set to Images Only.
    Once I switched it over it began working without problem.

    Thanks for the help!

  • #5 / Feb 27, 2012 4:18pm

    Shane Eckert

    7174 posts

    Hello Jonathan Morgan,

    I am glad to hear you found that setting and are back up and running now.

    Thank you for posting your question!

    Cheers,

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases