Hello all, i have this Javascript code for my redirect download page:
Redirect was fine, but i can't get the same file when i hit the link "Click Here" in the page redirected from origin download button "If your download does not start after 30 seconds, Click here"
Any idea? i want the same file at the redirect page from the previous download page.
Here is my download button link:
Thanks in advance.
- Code: Select all
<script type="text/javascript"> function DownloadAndRedirect() { var DownloadURL = "<cms:show download_link/>"; var RedirectURL = "/redirect.php"; var RedirectPauseSeconds = 1; location.href = DownloadURL; setTimeout("DoTheRedirect('"+RedirectURL+"')",parseInt(RedirectPauseSeconds*1000)); } function DoTheRedirect(url) { window.location=url; } </script>
Redirect was fine, but i can't get the same file when i hit the link "Click Here" in the page redirected from origin download button "If your download does not start after 30 seconds, Click here"
Any idea? i want the same file at the redirect page from the previous download page.
Here is my download button link:
- Code: Select all
<a href="javascript:DownloadAndRedirect()" target="_blank" style="border-radius:4px;padding: 20px;" class="btn btn-success btn-lg btn-block"><i class="fa fa-download" aria-hidden="true"></i> Download</a>
Thanks in advance.