473,699 Members | 2,386 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Start file download using onclick...

Hi all,

I'm creating an application for our needs and I want to make
something using JavaScript, but I don't know how. Hope somebody will
be able to give me hints on this.

When I click on a button, I want to start a file download. When I click
on the button, a new window open then the file download box appears. I
want to automatically close this new window to prevent confusion with
the users.

I found a link on the internet that do exactly I want to do:
http://www.vso-software.fr/download.htm and click on any "Download"
link. You will see an empty window open, then it will close then the
file download box will appear.

Hope you will understand well what I want to do.
Thanks to all.

Regards,
Yanick

Jul 23 '05 #1
1 4830
Certain file types, like EXE, are forced to do this by the browser. I am
also trying to cause the "save as" dialog box to pop up when a visitor
clicks on an MP3 link.

Any help is appreciated.

Kevin
wb****@yahoo.co m
"Yanick" <ne******@hotma il.com> wrote in message
news:11******** **************@ z14g2000cwz.goo glegroups.com.. .
Hi all,

I'm creating an application for our needs and I want to make
something using JavaScript, but I don't know how. Hope somebody will
be able to give me hints on this.

When I click on a button, I want to start a file download. When I click
on the button, a new window open then the file download box appears. I
want to automatically close this new window to prevent confusion with
the users.

I found a link on the internet that do exactly I want to do:
http://www.vso-software.fr/download.htm and click on any "Download"
link. You will see an empty window open, then it will close then the
file download box will appear.

Hope you will understand well what I want to do.
Thanks to all.

Regards,
Yanick


----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
6121
by: Brandon Walters | last post by:
I wrote a file download module for my website. The reason for the file download module is that my website downloads work on a credit based system. So I need to keep track of and limit daily downloads. It uses fpassthru() and some headers() to send a file to the requesting user. The get.php file that I wrote (the file download module if you will) works like a charm for .ZIP files and .TXT files. However, when .EXE files are downloaded...
2
21809
by: James T Kirk | last post by:
How can I create a link to a zip/exe file, that will start a download and then redirect to another page. The files being downloaded will be different, but the page to be directed to will stay the same. I want the redirect to happen as soon as the download begins... How can I do this ?
2
2002
by: Tom Youngquist | last post by:
I am trying to download a text file that my .NET page has just created based on entered parameters on the web page. Everything seems to work and the file is created. I am using the following code to start the download process: Response.Clear() Response.ContentType = "text/plain" Response.AppendHeader("Content-Disposition", "attachment; filename=" & fileName) Response.AppendHeader("Content-Description", "This is your Cost Journal...
2
4681
by: Ole Hanson | last post by:
Hi It seems to be virtually impossible to perform a download of more than 2 files at the time from any website? The same limitation seems to be put on IE, if I'm using that as Client. I want to create a simple download manager, that can perform mayby 25 downloads at the same time. What presents the limitation? The WebClient class or the server in the other end?
13
3307
by: bmurphy | last post by:
Last week after much searching, I found the answer to my problem in this newsgroup. I can't find the thread from which I got my solution, but I wanted to report back what worked. When the site visitor fills out the form and submits it, this calls a rather ordinary asp script like formmail.asp that sends the emails and displays a "thank you" web page. At the very end of my "thank you" web page I placed the following: <script...
4
3103
by: L. Scott M. | last post by:
I am invoking a file download using the following code: Response.Clear(); Response.AddHeader("Content-Disposition", "attachment; filename=" + downloadFile.Name); Response.AddHeader("Content-Length", downloadFile.Length.ToString()); Response.ContentType = "application/octet-stream";
2
2167
by: skulka3 | last post by:
Hello, I want to implement file downloads inside an authenticated web page, such that when a user clicks a link, the server side python code connects to a ftp server, downloads a relevant file and then streams the file to the browser for the user to open it with the appropriate application. In this case it will either be a pdf or a tiff file. This function is quite similar to something like writing raw bytes to a ServletOutputStream...
0
978
by: swheat | last post by:
Hello I would like to be able to automate downloading a file from a website which requires that I submit form parameters to start the download. The problem I am having is described exactly in this post by Jean-Marie: http://www.thescripts.com/forum/thread357970.html Cor responds that unattended downloads are not possible but that is incorrect. The webclient.downloadfile(uri) method works quite well unattended provided one has a uri to...
1
47462
KevinADC
by: KevinADC | last post by:
Note: You may skip to the end of the article if all you want is the perl code. Introduction Many websites have a form or a link you can use to download a file. You click a form button or click on a link and after a moment or two a file download dialog box pops-up in your web browser and prompts you for some instructions, such as “open” or “save“. I’m going to show you how to do that using a perl script. What You Need Any recent...
0
8613
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9172
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9032
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
7745
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6532
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4374
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3054
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2344
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.