|
Re: Viewer fails for pdf running https and IE [message #158136 is a reply to message #158114] |
Thu, 04 May 2006 04:52  |
Eclipse User |
|
|
|
Originally posted by: jarle.logit-systems.com
According to a number of posts "out there" this probably had something to
do with the respose header for "Chache-Control" being "no-cache". Because
of this I wanted to set the "Cache-Control" to "no-store" which should
cause the pdf document never to be cached and should not even be stored in
a temporary location on disk. I also set "Pragma" to "no-store" to support
older browsers.
I downloaded the source code for birt, as described in
http://www.eclipse.org/birt/phoenix/build/buildInstructions. php
In the project "org.eclipse.birt.report.viewer" the file
" org.eclipse.birt.report.viewer.aggregation.layout.EngineFrag ment.java " I
made some changes at line 54 - 59
original code:
else if ( ParameterAccessor.PARAM_FORMAT_PDF.equalsIgnoreCase(
ParameterAccessor.getFormat( request ) ) )
{
response.setContentType( "application/pdf" ); //$NON-NLS-1$
}
else
{
response.setContentType( "text/html;charset=utf-8" );//$NON-NLS-1$
response.setHeader( "cache-control", "no-cache" );
//$NON-NLS-1$//$NON-NLS-2$
}
modified code:
else if ( ParameterAccessor.PARAM_FORMAT_PDF.equalsIgnoreCase(
ParameterAccessor.getFormat( request ) ) )
{
response.setHeader( "cache-control", "no-store" );
response.setHeader( "Pragma", "no-store" );
response.setContentType( "application/pdf" ); //$NON-NLS-1$
}
else
{
response.setContentType( "text/html;charset=utf-8" );//$NON-NLS-1$
response.setHeader( "cache-control", "no-cache" );
//$NON-NLS-1$//$NON-NLS-2$
}
If this is a bug, should I report it in Bugzilla?
Regards Jarle
|
|
|
Powered by
FUDForum. Page generated in 0.02916 seconds