function onlyDigit(e)
{
    var reg = /[0-9]/;
 	var key;


 	// IE
 	if(window.event)
   	    key = String.fromCharCode(e.keyCode);
 	// FF, Opera, Netscape
 	else
   	    key = String.fromCharCode(e.which);
    t=e.keyCode;
    return t==8||t==9||t==46||reg.test(key);
}

var foto = '';
function popup(plik,x,y,inc)
{
     var w = screen.width;
     var h = screen.height;
     foto = plik;
     var lpos = (w-x)/2;
     var tpos = (h-y)/2;
     var dane = "width=" + x + ",height=" + y +",top=" + tpos + ",left=" + lpos + ",scrollbars=no";
     window.open(inc+'popup.html','obrazek',dane);
}