Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Save HTML without SaveAs Dialog.

Status
Not open for further replies.

jagi

Programmer
Mar 13, 2005
48
US
Hi,

I want to save the HTML file without popping SaveAs Dialog.
Code:
function doSaveAs(){
	if (document.execCommand)
         document.execCommand("SaveAs",false,'summaryHTML.html');
};

But the above code is still popping the dialog. I even tried with 'null' and 0 in place of false. But it didnt work. Can anyone tell me what the problem is ?

Thanks.


 
Google is a wonderful tool ;o)

Despite not saying anything on the SaveAs command detail page, my search (for "SaveAs execCommand dialog problem", incidentally) turned up on another MSDN article:


Microsoft's Web Team said:
the SaveAs command will ignore the showUI parameter and always prompt the user.

Sorry for the bad news!

Dan


[tt]D'ya think I got where I am today because I dress like Peter Pan here?[/tt]
[banghead]
 
[sarcasm]I'd love it if web designers could save any and all of their pages to my computer without my permission.[/sarcasm]

Lee
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top