Strange error with Response.WriteFile and SSL

M

Martin Knopp

I have a site running under SSL. Works well so far but there is one ASPX
page which returns a dynamically created PDF file using Response.WriteFile.

When the browser requests this ASPX page via https (SSL) it displays a
message that secure and non secure items are to be displayed (free
translation from german so it might not be the exact wording in english).
When I say no (means non secure items are not displayed) my PDF still is
displayed - so it seems thats not the one causing the message.

Any ideas whats wrong or even better how to solve it?

Regards,
Martin Knopp
fecher GmbH
 
C

Chad Z. Hower aka Kudzu

Martin Knopp said:
I have a site running under SSL. Works well so far but there is one ASPX
page which returns a dynamically created PDF file using Response.WriteFile.

When the browser requests this ASPX page via https (SSL) it displays a
message that secure and non secure items are to be displayed (free
translation from german so it might not be the exact wording in english).
When I say no (means non secure items are not displayed) my PDF still is
displayed - so it seems thats not the one causing the message.

Any ideas whats wrong or even better how to solve it?

It means that somewhere in the content you are sending back are some http://
referendces instead of https:// references. You need to make all images, and
other external type links https://


--
Chad Z. Hower (a.k.a. Kudzu) - http://www.hower.org/Kudzu/
"Programming is an art form that fights back"


ELKNews - Get your free copy at http://www.atozedsoftware.com
 
M

Martin Knopp

That would have been easy!

I checked for this already and the only thing we return is a PDF document.
Nothing else.

Today I heard from some source that it might be a problem of IE. I will have
to further investigate this probably.

Any other ideas/hints?
 
G

George Ter-Saakov

How do you display a PDF?
Do you return the PDF document with proper content type?
Or are you displaying the HTML with embeded PDF?

George.
 
M

Martin Knopp

I return the PDF with proper contenttype

code-behind in Page_Load event (C#) looks approximately like this:

Response.Clear();
Response.ContentType = "appilcation/pdf";
Response.WriteFile( <local path to PDF document> );
Response.End();

Regards,
Martin Knopp
fecher GmbH
http://www.fecher.at
 
H

Hermit Dave

go to aspx page you are using for downloads and check to see if in html view
you see any html / aspx elements (if yes remove them)
because when you call Response.Flush they will not be cleared unless you
have default Buffer = true applicable across

a better option for downloads is to use ashx... it httphandler you... they
do offer a performance boost of around 5 - 10%
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,904
Latest member
HealthyVisionsCBDPrice

Latest Threads

Top