// JavaScript Document
//<meta http-equiv="Content-Type" content="text/html; charset=utf-8">


jQuery(function($){

	$("#cryptSending").hide();
	
	$("#cryptBtn")
	.click(function () {
			$.ajax({
				type:"post",
				url: "./lib/crypt.php",
				data :{
				"cryptPwd":$("#cryptPwd").val()
			},
			beforeSend:function(msg,status){
				
				if($("#cryptPwd").val().length == 0 ){
					$("#cryptChangeArea").html("<span style=\"color:#ff0000;\">パスワードが入力されていません</span>");
					$("#cryptChangeArea").fadeIn("fast");
					return false;
				}
				$("#cryptSending").show();
			},
			success:function(msg,status){
				$("#cryptChangeArea").hide();
				$("#cryptChangeArea").html(msg);
				$("#cryptChangeArea").fadeIn("fast");
				$("#cryptSending").hide();
			}
		});
	});
});

