Invoking Save As dialogue box

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

There's a Javascript method of invoking the Save As dialogue box from a
web page browsed in IE. It uses
document.execCommand('SaveAs',null,'filename.htm'). However this causes
a "Save HTML Document" dialogue box to open which does not have the
ability to "Save as type" "Web page, complete" ie complete with an
images folder. I wish to emulate the IE browser File > Save as...
facility which opens a "Save Web Page" dialogue box which does have the
"Web page, complete" option. Is there another form of the
document.execCommand which will open the "Save Web Page" dialogue box
rather than the "Save HTML Document" dialogue box? The principle is
shown at

Re: Invoking Save As dialogue box

Quoted text here. Click to load it

Perhaps you are seeing the "Save HTML Document" dialog box because you
specified an HTML file type in the command: 'filename.htm'.  You might try
leaving the vValue option empty, or specify ".mht" for the option.  Take a
look at

George King
G.E. King Marketing

Re: Invoking Save As dialogue box

George, thanks for the reply. Leaving the value empty still doesn't
give me the "Save Web Page" dialogue box, and ".mht" isn't a suitable
format for us. So the search for a solution to my problem continues...
regards, Carl

Re: Invoking Save As dialogue box

On 23 Jun 2005, carl wrote:

Quoted text here. Click to load it

As an alternative, you could write a batch file that creates another
batch file on the fly to run wget with the appropriate switches to fetch
the page in question and all of the images linked to from that page.
That might work for you.

I have used one batch file to fetch my home page and everything it links
to (and, recursively, everything linked to by what it links to) that is
in my own directory in order to mirror the entire public part of my web
site.  With ": " prepended to all lines.  Those without ": " are wrapped
following a trailing space in the previous line.  Only the last line is
really significant.  The others just change the palette and clear the
screen to a nice readable bright white on red so I can see the progress
at a glance.  "p.bat" sets the path to make the other utilities

: @echo off
: call c:\WINDOWS\p.bat
: c:\utils\vga pal c:\utils\win2.pal
: call cl
: @echo on
: G:\utils\Win\wget -r -I /~af380 -nH --cut-dirs=1

It even creates subdirectories as necessary.

Switches may vary between the version you get and the version I have.
The download for the version I have has been visited by the 404 Fairy.
Other wget URLs in my bookmarks include:

"GNU wget - GNU Project - Free Software Foundation (FSF)"
" : man : wget"

Windows is *not* a "Toy OS".
/me desperately trying to hide the URL for the screenshot of my desktop

Site Timeline