...

View Full Version : printing in mozilla



nectar
07-15-2003, 05:42 PM
I'm having a problem printing in mozilla , it says that the page was replaced, please try again.
The script below opens a new window prints and closes. Works in ie but not in mozilla, I assume due to some error of mine in the script. Would appreciate any help
Thanks

<script language="JavaScript" type="text/javascript">
var printPage;
function printPage()
{
printPage = window.open('recipe_print.htm');
printPage.blur();
printPage.print();
setTimeout("printPage.close()",600);
}
</script>

Danne
07-15-2003, 05:56 PM
Maybe you can try to put the print code in 'recipe_print.htm':




document.onload=function() {
self.print();
setTimeout('close();',600);
}

nectar
07-15-2003, 08:42 PM
Thanks for your reply. Had to adjust it a bit to work in explorer, but still doesnt work in mozilla, with slight adjustments the window of my printer comes up in mozilla, press ok, and...nothing.
Must be a simple error, because I'm sure I got it working once, but my javascript isnt good enough to see the error.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum