/*
	FormCheck Javascript Ver:1.0 Scripting By Yoshiro 2002.01.26
*/

function formCheck() {
    var mailstr=/[^-A-Za-z0-9@._\/%\-]/;
    var mailstr2=/[^-A-Za-z0-9._\/%\-]/;
    var passstr=/[^-A-Za-z0-9]/;
    var numstr=/[^-0-9]/; //先頭の'-'ハイフンでハイフンも含む

    if( document.Contact.name.value == "" ) {
		window.alert( "お名前を入力してください。" );
		return false;
		}
		
		if( document.Contact.name.value == "" ) {
		window.alert( "お勤め先を入力してください。" );
		return false;
		}
		
		if( document.Contact.zip.value.length < 8 ) {
		window.alert( "郵便番号を入力してくだい。" );
		return false;
		}
		
		if( numstr.test(document.Contact.zip.value) ) {
		window.alert( "郵便番号に使用できない文字が含まれています。" );
		return false;
		}
		
		if( document.Contact.add.value == "" ) {
		window.alert( "ご住所を入力してください。" );
		return false;
		}
		
		if( document.Contact.tel.value == "" ) {
		window.alert( "電話番号を入力してください。" );
		return false;
		}
		
		if( numstr.test(document.Contact.tel.value) ) {
		window.alert( "電話番号に使用できない文字が含まれています。" );
		return false;
		}
		
		if( document.Contact.mail.value == "" ) {
		window.alert( "メールアドレスを入力してください。" );
		return false;
		}
		
		if( document.Contact.mail.value.indexOf("@",0) == -1 ) {
		window.alert("メールアドレスに @ が含まれていません。");
		return false;
		}
		
		if( mailstr.test(document.Contact.mail.value) ) {
		window.alert("メールアドレスに使用できない文字が含まれています。");
		return false;
		}
		
		return true;
		
}
