function check_del(addr)  
{
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Opravdu si přejete položku smazat?</strong></p><p><a href="'+ addr +'"><img src="/images/layout/button-delete.png" style="" alt="" /></a></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      

}

function check_edit(addr)  
{
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Opravdu si přejete položku upravit?</strong></p><p><a href="'+ addr +'"><img src="/images/layout/button-save.png" style="" alt="" /></a></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      

}

function check_form()  
{
  var flg = 1;

  if((document.Form.e1.value)=="") {flg = 0};
                
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}
	return true;
}

function check_form_2()  
{
  var flg = 1;

  if((document.Form.e1.value)=="") {flg = 0};
  if((document.Form.e3.value)=="") {flg = 0};
                
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}
}

function check_form_3()  
{
  var flg = 1;

  if((document.Form2.e2.value)=="") {flg = 0};
                
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}
}

function check_form_4()  
{
  var flg = 1;

  if((document.Form.e4.value)=="") {flg = 0};

  if((document.Form.e7.value)!="") {
  	var emailFilter=/^.+@.+\..{2,3}$/;  
    if (!emailFilter.test(document.Form.e7.value)) {flg = 2;}
  }
                
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);  
        
  	return false;
	}	
	
  if(flg == 2){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>E-Mailová adresa je ve špatném formátu.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);
  	
  	return false;
	}
}

function check_form_5()  
{
  var flg = 1;

  if((document.Form2.e21.value)=="") {flg = 0};
  if((document.Form2.e22.value)=="") {flg = 0};
  if((document.Form2.e25.value)=="") {flg = 0};
                
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><img src="/images/icons/sicon4.png" style="float:left" alt="" /><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}
}

function check_form_w()  
{
  var flg = 1;

  if((document.Form.e1.value)=="") {flg = 0};
  if((document.Form.e3.value)=="") {flg = 0};

  if((document.Form.e2.value)!="") {
  	var emailFilter=/^.+@.+\..{2,3}$/;  
    if (!emailFilter.test(document.Form.e2.value)) {flg = 2;}
  }
                
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}

  if(flg == 2){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><p style="font-size:14px;"><strong>E-Mailová adresa je ve špatném formátu.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}	
	
	return true;
}

function check_form_c()  
{
  var flg = 1;

  var emailFilter=/^.+@.+\..{2,3}$/;  
  if (!emailFilter.test(document.Form.e2.value)) {flg = 2;}
       
  if((document.Form.e1.value)=="") {flg = 0};
  if((document.Form.e3.value)=="") {flg = 0};
         
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}

  if(flg == 2){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><p style="font-size:14px;"><strong>E-Mailová adresa je ve špatném formátu.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}	
	
	return true;
}
	
function check_form_r()  
{
  var flg = 1;

  var emailFilter=/^.+@.+\..{2,3}$/;  
  if (!emailFilter.test(document.Form.e10.value)) {flg = 2;}
       
  if((document.Form.e1.value)=="") {flg = 0};
  if((document.Form.e2.value)=="") {flg = 0};
  if((document.Form.e3.value)=="") {flg = 0};
  if((document.Form.e4.value)=="") {flg = 0};
  if((document.Form.e5.value)=="") {flg = 0};
  if((document.Form.e6.value)=="") {flg = 0};
  if((document.Form.e7.value)=="") {flg = 0};
  if((document.Form.e8.value)=="") {flg = 0};
  if((document.Form.e9.value)=="") {flg = 0};
         
  if(flg == 0){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><p style="font-size:14px;"><strong>Vyplňte prosím všechny povinné položky.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
  }

  if(flg == 2){
  	
  	$.fancybox(
  		'<div style="margin:15px;width:300px;"><h2>Upozornění</h2><p style="font-size:14px;"><strong>E-Mailová adresa je ve špatném formátu.</strong></p></div>',
  		{
    		'transitionIn'	:	'elastic',
    		'transitionOut'	:	'elastic',
    		'speedIn'		:	600, 
    		'speedOut'		:	200, 
    		'hideOnContentClick': true,
    		'overlayOpacity': 0.25
  		}
  	);      
  	
  	return false;
	}	
	
	return true;
}
