• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1338
  • Last Modified:

How to open a ".odt" file in browser instead of download it?

Hello,

I'm trying to execute a jasper report that exports to odt (OpenOffice). The report is working fine, but when it opens, the browser asks if the user wants to open or to save the report. I want to open in the browser, like pdf. Is it possible?

I'm using this header:
resp.setHeader("Content-Disposition"," inline; filename=Report.odt");
                  //resp.setContentType("application/vnd.oasis.opendocument.text");
                  resp.setContentType("application/odt");
                  facadeReport.executeODT( out, reportCmd.getReport(),map );

Thanks...
0
arthur_info
Asked:
arthur_info
1 Solution
 
CEHJCommented:
You'd need to have a browser plugin for that - not sure if one exists
0
 
chilternPCCommented:
if you download and install open office it will also install a plugin for the browser
see www.openoffice.org
0
 
ICaldwellCommented:
No, the open office does not have a reader interface like the Acrobat PDF reader, you will have to download the file to open it.....

The other solution would be to use an online viewer like this:  http://www.viewdocsonline.com/

Read the legal stuff before using this though....
0
 
arthur_infoAuthor Commented:
ok... Thanks...
0
 
chilternPCCommented:
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now