File Download Dialog Box -Help

  • Thread starter Surjit Madiwalar
  • Start date
S

Surjit Madiwalar

Hi,

I want to get dialog box(open,save,cancel) for pdf file using asp(vbscript).
Presently when i click on pdf link on the site..the pdf document opens in
the browser.

I have used the below code(download.asp?file=filename):

<%
Response.AddHeader "content-disposition", "attachment; filename=" &
request.querystring("file")
Response.ContentType = "application/octet-stream"
%>

This file resides in the same dir of pdf documents

Eg:

Downloads
|
--1.pdf
|
--2.pdf
|
download.asp

But when i request download.asp with the filename i get dialog box..but when
i open the pdf file..it gives error saying document can't be read....

Please let me know your suggestions/inputs.

Rgds,
Surjit
 
S

Steven Scaife

I may be wrong but couldn't this be a client side browser issue. There will
probably be an option in internet explorer that makes it give you the
choice.

dont quote me on it though
 

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,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top