// JavaScript Document

var win = null;

function nuevaVentana(pagina,nombre,w,h,scroll){
	LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
	TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
	estilo ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable';
	win = window.open(pagina,nombre,estilo);
}


function showLightbox() {
	document.getElementById('over').style.display='block';
	document.getElementById('fade').style.display='block';
}
function hideLightbox() {
	document.getElementById('over').style.display='none';
	document.getElementById('fade').style.display='none';
	$jQ("#content").html("");
}


function showLightbox2() {
	document.getElementById('over2').style.display='block';
	document.getElementById('fade2').style.display='block';
}
function hideLightbox2() {
	document.getElementById('over2').style.display='none';
	document.getElementById('fade2').style.display='none';
	$jQ("#content2").html("");
}


function cargarVideo(videoid){
		
		showLightbox();
		
		$jQ.ajax(
				{
			    type: "GET",
				url: "video.php?id=" + videoid,
			    async:false,
				success: function(data){
						 $jQ("#content").html(data);
				}
		});	
}

function cargarEmpleado(){
		
		showLightbox2();
		
		$jQ.ajax(
				{
			    type: "GET",
				url: "empleado-del-mes/index.php",
			    async:false,
				success: function(data){
						 $jQ("#content2").html(data);
				}
		});	
}