how to display filedownload dialog using javascript.
Announcement
Collapse
No announcement yet.
how to display filedownload dialog using javascript.
Collapse
X
-
AFAIK, just create a link to it. If the file is of a certain type (ie: files that the browser can't display, or parse, or whatever; ie: ZIP files, EXE files), then the browser will display a download dialog. There's no way I know of to force this dialog using script.
-
If you want to display the download dialog even if the extension is txt, html, gif or any other extension that browser can display, then you need a server-side language (ASP, PHP, JSP, etc) to do it.
Comment
-
Originally posted by Spudhead
AFAIK, just create a link to it. If the file is of a certain type (ie: files that the browser can't display, or parse, or whatever; ie: ZIP files, EXE files), then the browser will display a download dialog. There's no way I know of to force this dialog using script.
Comment
-
Originally posted by glenngv
If you want to display the download dialog even if the extension is txt, html, gif or any other extension that browser can display, then you need a server-side language (ASP, PHP, JSP, etc) to do it.
Comment
-
You must tell first what server-side language you use. I have an ASP script that I think came from [email protected]
Comment
-
Originally posted by glenngv
You must tell first what server-side language you use. I have an ASP script that I think came from [email protected]
Comment
-
Comment