• Hi all,

    On a portal i’m uploading different files that users can view or download.
    Files like pdf, excel and word.

    Pdf and word can be viewed or be download from the portal, only excel files not.
    When clicking on a link of a excel file that is uploaded to the media library i get a white blank page and nothing happen.

    I’ve done the following things to try to get this working.
    Add excel file type to allowed upload files in the .htaccess
    add mime types in cpanel of the hosting.

    Has anyone a idea or sollution for this?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Did you get this resolved? Do you have a link?

    Thread Starter Ralph Janssen

    (@kreatif)

    No, not yet.

    I contacted the hosting provider for help.
    They adviced me to add the following mimetypes to the htaccess.
    This doesn’t work eather.

    AddType application/vnd.ms-excel .xls
    AddType application/vnd.openxmlformats-officedocument.spreadsheetml.sheet .xlsx

    Direct link to a test excel file.
    http://betrokkeninheerlen.nl/intranet/wp-content/uploads/2016/02/test.xls

    This is very odd! Could it be a security plugin issue? Or other plugins, maybe a cache plugin issue?

    You said you added the Excel type as an allowed upload type, but that doesn’t appear to be the issue unless users are uploading their own excel files to your site. When I went to the link you posted, I also got a blank page, but after doing an Inspect Element, the actual error that is coming up is “Failed to load resource: the server responded with a status of 403 (Forbidden)”

    So, for whatever reason, the server is protecting the file. Maybe check the permissions on this file to allow for download? I have hosted and allowed Excel files to download from sites before with no issue. However, I had them available for download from a “button” that opened on a new window for download.

    This is puzzling indeed!

    Thread Starter Ralph Janssen

    (@kreatif)

    Found the probleem.
    It was indeed a promission issue.
    There was a .htaccess in de upload folder with a rule for allowing file types.

    Excel wasn’t included in this rule..

    Ah! That makes sense! Glad it’s fixed now! 😀

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Download excel files’ is closed to new replies.