Click to See Complete Forum and Search --> : script for printing in different browser


bloodspecter
05-26-2003, 11:44 AM
I need some pros help for a some line of code I've found in the forum, here's the code:

<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function myPrintFunction(){
window.setTimeout("winPtr.close()",15000);
winPtr = window.open("", "myWin"), "width=800,height=600";
winPtr.location.href = "document.htm"
winPtr.focus();
winPtr.print();
}
// End -->

This script is made to open a window, open the print box and close the window after some time.

What I would like to know is if this script will work on most of the browser like netscape, mozilla, conqueror etc.. have no way of knowing here.

If the script don't work, can you tell me how I may be able to make it work on as much browser as possible? I already know it's working in microsoft explorer.

Thank you.

khalidali63
05-26-2003, 11:57 AM
it should work on most of the browsers that support JavaScript..

bloodspecter
05-26-2003, 11:58 AM
That would be a relief. Thank you

khalidali63
05-26-2003, 12:06 PM
you are welcome for my great effor in helping ya..

:D

bloodspecter
05-27-2003, 07:13 AM
There is a problem with mozilla, 4.7 read the script perfectly but a more recent version isn't able to open the correct file, but the rest work fine.

Can you help me?