var faux = null;
var pic = new Image(); 

function copyCat(pic,br,lg) 
{
faux = window.open('','newWin','dependent,resizable,top=20,left=20,width=550,height=380');
var fd = faux.document;
faux.resizeTo(br,lg);
fd.open();
fd.write('<html><head><title>RCM Reifen Center Moelter</title></head>');
fd.write('<body bgcolor="white" onLoad="window.focus()">');
fd.write('<p><FONT face="Arial"><a href="javascript:window.print()">Drucken - Imprimer - Print</a></FONT></p>');
fd.write('<table border="0" cellpadding="0" cellspacing="0" width="100%" height="80%">');
fd.write('<tr><td align="center" valign="middle"><img src="' + pic + '"></td></tr>');
fd.write('</table>');
fd.write('</body></html>');
fd.close();
}


function openHTML(source,width,height)
{	var win;
	var str;
	str  = ""; 
	str += "resizable=yes,scrollbars=yes,location=no,titlebar=no,"; 

	str += "width=" + width + ","; 
	str += "height=" + height; 
 		
	if ( window.screen) { 
		var ah = screen.availHeight - 30; 
		var aw = screen.availWidth - 10; 
 
		var xc = ( aw - width ) / 2; 
		var yc = ( ah - height ) / 2; 
 
		str += ",left=" + xc + ",screenX=" + xc; 
		str += ",top=" + yc + ",screenY=" + yc; 
	} 
	win=window.open(source,'MK',str);
	win.focus();
}

function clickButton(e, buttonid){ 
     var bt = document.getElementById(buttonid); 
     if (typeof bt == 'object'){ 
            if(navigator.appName.indexOf("Netscape")>(-1)){ 
                  if (e.keyCode == 13){ 
                        bt.click(); 
                        return false; 
                  } 
            } 
            if (navigator.appName.indexOf("Microsoft Internet Explorer")>(-1)){ 
                  if (event.keyCode == 13){ 
                        bt.click(); 
                        return false; 
                  } 
            } 
            if (navigator.appName.indexOf("Opera")>(-1)){ 
                  if (event.keyCode == 13){ 
                        bt.click(); 
                        return false; 
                  } 
            } 
      } 
} 
