function check(form)
{
	var re = new RegExp("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$","ig");	
	if(form.Email.value!="" & (arr=re.exec(form.Email.value)) == null){
		alert("Eメールをチェックしてください");
		return false;
	}
	if(form.UserName.value.length< 1 ){
		alert("お名前を記入してください。");
		return false;
	}
	if(form.Subject.value.length< 1 ){
		alert("タイトルを記入してください。");
		return false;
	}
	if(FCKeditorAPI.GetInstance("Content").GetXHTML()==""){
		alert("本文を入力してください。");
		return false;
	}
	var http_re = new RegExp("^http://{1}([_a-z0-9-]+[.]){1,3}","i");
	if(form.URL.value!="" & http_re.exec(form.URL.value) == null){
		alert("ホームページをチェックしてください");
		return false;
	}	
	if(form.lg_num)	{
		if(form.lg_num.value.length< 1)	{	
			alert("認証コードをチェックしてください。");
			return false;
		}
	}
	if(form.Password.value.length< 1){
		alert("管理キーを入力してください。");
		return false;
	}

}



function Imgfile()
{

	var frm=document.getElementById('UserImg');
	frm.disabled=false;
}

var flag=false; 
/*function DrawImage(ImgD){ 
	alert('ok');
	var image=new Image(); 
	image.src=ImgD.src; 
 	if(image.width>0 && image.height>0){ 
 		flag=true; 
  		if(image.width/image.height>= 120/60){ 
   			if(image.width>120){  
   				ImgD.width=120; 
   				ImgD.height=(image.height*120)/image.width; 
   			}else{ 
   				ImgD.width=image.width;  
   				ImgD.height=image.height; 
   			} 
   		}else{ 
   			if(image.height>60){  
   				ImgD.height=60; 
   				ImgD.width=(image.width*60)/image.height;    
   			}else{ 
   				ImgD.width=image.width;  
   				ImgD.height=image.height; 
   			} 
   		} 
	} 
}*/

