By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,760 Members | 1,644 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,760 IT Pros & Developers. It's quick & easy.

How to redirect after the download starts

P: n/a
Hi,

I am having a requirement where in user can click on a link and the download
popup appears and then user should be redirected to a congratulations page.

We didn't bother whether the download is successful or not but as soon as
user clicks on the download link the popup appears, and then the user should
be directed to the congratulations page.

I have written the standard code to download the file but after that i am
unable to redirect the user to another page.

Can anybody help me out to achive the same.

--
Thanks
Hitesh
Nov 19 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
You probably will have to use window.open( '' ) to start the download, then
in your parent window, redirect to the congratulations page.

bill
"Hitesh" <Hi****@discussions.microsoft.com> wrote in message
news:8C**********************************@microsof t.com...
Hi,

I am having a requirement where in user can click on a link and the download popup appears and then user should be redirected to a congratulations page.
We didn't bother whether the download is successful or not but as soon as
user clicks on the download link the popup appears, and then the user should be directed to the congratulations page.

I have written the standard code to download the file but after that i am
unable to redirect the user to another page.

Can anybody help me out to achive the same.

--
Thanks
Hitesh

Nov 19 '05 #2

P: n/a
Hi William,

Thanks for your sugggestion and its working too but i have one question
related to this suggestion and i guess you probably expecting it!

The thing is what about the window that gets opened up, do we have any way
to hide that window? Because for users its difficult to accept that a window
appears just becuase they are downloading something.
--
Thanks
Hitesh
"William F. Robertson, Jr." wrote:
You probably will have to use window.open( '' ) to start the download, then
in your parent window, redirect to the congratulations page.

bill
"Hitesh" <Hi****@discussions.microsoft.com> wrote in message
news:8C**********************************@microsof t.com...
Hi,

I am having a requirement where in user can click on a link and the

download
popup appears and then user should be redirected to a congratulations

page.

We didn't bother whether the download is successful or not but as soon as
user clicks on the download link the popup appears, and then the user

should
be directed to the congratulations page.

I have written the standard code to download the file but after that i am
unable to redirect the user to another page.

Can anybody help me out to achive the same.

--
Thanks
Hitesh


Nov 19 '05 #3

P: n/a
When you open a new window to another address, it will open the new window.
When the only thing sent by the server to the "new" browser window, is a
downloaded file, on my Windows 2000 Client, it basically closes out the
window and switches to a dowload dialog.

You will probably want to test this, but I believe it should work.

bill

"Hitesh" <Hi****@discussions.microsoft.com> wrote in message
news:7D**********************************@microsof t.com...
Hi William,

Thanks for your sugggestion and its working too but i have one question
related to this suggestion and i guess you probably expecting it!

The thing is what about the window that gets opened up, do we have any way
to hide that window? Because for users its difficult to accept that a window appears just becuase they are downloading something.
--
Thanks
Hitesh
"William F. Robertson, Jr." wrote:
You probably will have to use window.open( '' ) to start the download, then in your parent window, redirect to the congratulations page.

bill
"Hitesh" <Hi****@discussions.microsoft.com> wrote in message
news:8C**********************************@microsof t.com...
Hi,

I am having a requirement where in user can click on a link and the

download
popup appears and then user should be redirected to a congratulations

page.

We didn't bother whether the download is successful or not but as soon as user clicks on the download link the popup appears, and then the user

should
be directed to the congratulations page.

I have written the standard code to download the file but after that i am unable to redirect the user to another page.

Can anybody help me out to achive the same.

--
Thanks
Hitesh


Nov 19 '05 #4

P: n/a
Hi William,

Did you mean to say that the window never appears up on your client. On my
side it apears and be there untill the user made their choice (open, save,
cancel) about the download. Once they made the choice the window gets closed
automatically.

What i am looking for is there any way so that the window never appears. Is
this possible from your last answere it seems that you are not getting the
window at all and there is not other thing on that page except the download
code.

Please share your thoughts on this. And till now what ever you are
suggesting is taking me into the right direction so thanks for it!
--
Thanks
Hitesh
"William F. Robertson, Jr." wrote:
When you open a new window to another address, it will open the new window.
When the only thing sent by the server to the "new" browser window, is a
downloaded file, on my Windows 2000 Client, it basically closes out the
window and switches to a dowload dialog.

You will probably want to test this, but I believe it should work.

bill

"Hitesh" <Hi****@discussions.microsoft.com> wrote in message
news:7D**********************************@microsof t.com...
Hi William,

Thanks for your sugggestion and its working too but i have one question
related to this suggestion and i guess you probably expecting it!

The thing is what about the window that gets opened up, do we have any way
to hide that window? Because for users its difficult to accept that a

window
appears just becuase they are downloading something.
--
Thanks
Hitesh
"William F. Robertson, Jr." wrote:
You probably will have to use window.open( '' ) to start the download, then in your parent window, redirect to the congratulations page.

bill
"Hitesh" <Hi****@discussions.microsoft.com> wrote in message
news:8C**********************************@microsof t.com...
> Hi,
>
> I am having a requirement where in user can click on a link and the
download
> popup appears and then user should be redirected to a congratulations
page.
>
> We didn't bother whether the download is successful or not but as soon as > user clicks on the download link the popup appears, and then the user
should
> be directed to the congratulations page.
>
> I have written the standard code to download the file but after that i am > unable to redirect the user to another page.
>
> Can anybody help me out to achive the same.
>
> --
> Thanks
> Hitesh


Nov 19 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.