PDA

Click to See Complete Forum and Search --> : [resolved] Calling IE's Save As dialog box


solitario
Jul 31st, 2004, 01:39 AM
Hello all.
I have a function which calls the Save As dialog box in Internet Explorer. However, I have this on a PHP page and when the dialog box appears, the default File name comes with the *.php extention. Is there any way I can tell the dialog box to display it with an *.htm extension?

Many thanks.<script>
function SavePage(){document.execCommand("SaveAs");}
</script>

<a href="javascript:SavePage();">

Acidic
Jul 31st, 2004, 06:20 AM
I'm almost entirely sure that that's non-standard which means you'll have a hard time finding help on it. I'll have a look on msdn for you.

Stupid me, no JavaScript is standard as there is no standard for it. still having a look though.

Acidic
Jul 31st, 2004, 06:31 AM
well. This is hat I found (http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/methods/execCommand.asp). It's not very promising. I didn't quite get it all, you can try experimenting with the parameters, but I don't know.