Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: Report Viewer - Output type - filename extension missing

  1. #1
    Join Date
    Jan 2015
    Posts
    4

    Default Report Viewer - Output type - filename extension missing

    Selecting a PDF, Excel or CSV output type when viewing a report displays a file download dialog with the file extension missing:
    Name: report
    Type: Unknown File Type

    I found an archived forum post wich seemed to describe the exact issue I am having, but I'm not sure if the solution is relevant in the current version?

    http://forums.pentaho.com/showthread...-pdf-extension

    Is there any solution to this with the current version?

    As you may know, the targeted end users of BI systems are rarely technically savvy and may struggle with appending filetypes when downloading/exporting reports and will likely consider the report 'broken'.

    Any help is appreciated, Laz

  2. #2

    Default

    I have fixed it by compiling my own servlet and replacing original one.

    org.pentaho.platform.web.servlet.GetContent

    if (!mimetype.equalsIgnoreCase("text/html")) {
    String fileName = contentItem.getTitle();
    fileName = fileName.replace(' ', '_');
    fileName = fileName + MimeHelper.getExtension(mimetype);
    response.setHeader("Content-Disposition", "inline; filename=\"" + fileName + "\"");
    }
    Now it works OK.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.