Solved

JavascRipt Modal Window

Posted on 2011-09-30
3
206 Views
Last Modified: 2012-06-27
I am using Javascript Modal Window and I have a Button inside that Modal Widow. I want that when i click on that Button, it should go to other Page and Immeditely Prompt me to download the ecel file, i have written the logic for downloading the file in that page..

Please guide how can i do. if there is another Way, Let me know

Me using Coldfusion.

Currently i am trying with location.href, but it is giving me an error

like this

<input type="button" name="btn  value="Click" onclick="location.href='abc.cfm?id=#id#';">

0
Comment
Question by:myselfrandhawa
  • 2
3 Comments
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 36895517
What error in what browsr on what platform.
Is the cfm returning application/octet-stream as it is supposed to for download or something else? Please provide more detail.
Code example or URL would be useful too
 
0
 
LVL 15

Accepted Solution

by:
myselfrandhawa earned 0 total points
ID: 36895774
hi, i solved it using the <a href tag inside the modal window and setting its target to the name of the iframe inside the modal window. the height/width of modal window was set to 0 px to as to make it invisible.. and it worked

Regards

Thanks mplungjan!
0
 
LVL 15

Author Closing Comment

by:myselfrandhawa
ID: 36935352
use an iframe inside the showmodal dialog and set the attribute of a tag tagrget to the iframe name done!
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
This article discusses how to create an extensible mechanism for linked drop downs.
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now