$(document).ready(function(){
//DESPLIEGA COSAS
//registro usuarios noticias  
$("#nuevo_user").click ( function (){
      $("#user_nuevo").toggle(1000);
    });
//ver normas uso noticias	
$("#normas_coment").click ( function (){
      $("#comentanormas").toggle(1000);
    });

//mostrar y ocultar cronicas	
$("#mostrarcron").click ( function (){
      $("#minutocron").toggle(1000);
    });   
$("#cerrarcron").click ( function (){
      $("#minutocron").toggle(1000);
    });   
 

/*           SLIDESHOW*/

$('#banner_rotatorio').cycle({ 
    fx:'fade', 
});

$('#banner_rotados').cycle({ 
    fx:'fade', 
});



       
});

	
function abreimg(esta){
	var d=document.getElementById("gl_"+esta).clientHeight; 
	var anch=document.getElementById("gl_"+esta).clientWidth; ;
	    if(anch<130){
		    sumamas=((d*100)/anch)+d;  
			sumancho=(100+anch);
			
	             document.getElementById("gl_"+esta).style.height=sumamas+"px";
	             document.getElementById("gl_"+esta).style.width=sumancho+"px";
	    }
	return false;	
}


	
function cierraimg(esta){
	var d=document.getElementById("gl_"+esta).clientHeight; 
	var anch=document.getElementById("gl_"+esta).clientWidth; ;
	    if(anch>130){
		    sumamas=d-((d*100)/anch);  
			sumancho=(anch-100);
			
	             document.getElementById("gl_"+esta).style.height=sumamas+"px";
	             document.getElementById("gl_"+esta).style.width=sumancho+"px";
		}
    return false;		
}
