Using javascript to make a pop-up dialog when page loads

I'm using a web application (using ColdFusion 9) to create  an excel file to give to the user to download.  When the page reloads the following is run

window.location.href = '#application.settings.absoluteURL#modules/';

This exectedly creates a dialog where the user can "save-as" the file.  However, this makes javascript on the page break (including some jquery items).  Is there an alternative javascript call to prompt a user with "save-as" dialog WHEN th epage loads.  Would prefer to not have to have them press a link.

Who is Participating?
so the user clicks a link and the page reloads?  since you're already using jquery, what about triggering the download from the initial link? I haven't used it, but here's one example using the jqueryfiledownload plugin

//With jquery.fileDownload.js
//bare-bones stock setup
$(document).on("click", "a.fileDownloadStock", function () {
    var linkHref = $(this).attr('href');
    return false; //this is critical to stop the click event which will trigger a normal file download!

Open in new window

HyperBPPAuthor Commented:
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.