public void appendToResponse(WOResponse response, WOContext context)
{
super.appendToResponse(response, context);
try {
response.disableClientCaching();
response.removeHeadersForKey("Cahce-Control");
response.removeHeadersForKey("pragma");
//response.setHeader("application/octet-stream","content-type");
response.setHeader("application/force-download","content-type");
response.setHeader("inline; attachment; filename=\""+fileName+"\"","content-disposition");
response.setHeader(Integer.toString(getFileData().length()),"content-lenght");
response.setContent(getFileData());
}
catch (Exception e) {
System.out.println(e);
}
}
works great on any browser except internet explorer withc return an error message like unable to open site, site not found.