function popitup(id,width,height,nume)
{
	window.open('pop.php?id='+id,nume,'width='+width+',height='+height+',scrolling=auto,scrollbars=yes,resizable=no,status=yes,location=no,toolbar=no,menubar=no');
}

var newwindow;
function pop_up(url){
	newwindow=window.open(url,'','height=400,width=600,scrollbars=yes,title=no');
	if (window.focus) {newwindow.focus()}
}

function confirma()
{
input_box=confirm("Prin accesarea acestui site confirmati ca aveti peste 18 ani !");
if (input_box==true) return true;
	else return false;
}

function numbersonly(myfield, e, dec)
{
	var key;
	var keychar;
	
	if (window.event)
	   key = window.event.keyCode;
	else if (e)
	   key = e.which;
	else
	   return true;
	keychar = String.fromCharCode(key);
	
	// control keys
	if ((key==null) || (key==0) || (key==8) || 
		(key==9) || (key==13) || (key==27) )
	   return true;
	
	// numbers
	else if ((("0123456789").indexOf(keychar) > -1))
	   return true;
	
	// decimal point jump
	else if (dec && (keychar == "."))
	   {
	   myfield.form.elements[dec].focus();
	   return false;
	   }
	else
	   return false;
}

