function register_reinput() {
	document.mainform.action = "/Register/register/";
	document.mainform.submit();
}

function order_reinput() {
	document.mainform.action = "/Order/order/";
	document.mainform.submit();
}

function register_reedit() {
	document.getElementById('reedit').value = "1";
	document.mainform.action = "/Register/edit/";
	document.mainform.submit();
}

function question_reedit() {
	document.mainform.action = "/Question/input/";
	document.mainform.submit();
}

function image_delete(image_num) {
  if(window.confirm(image_num + "枚目を削除します。\n本当によろしいですか？\n")){
	document.getElementById('image_num').value = image_num;
	document.mainform.action = "/Mypage/deleteimage/";
	document.mainform.submit();
  }
}
function image_insert(image_num) {
	document.getElementById('image_num').value = image_num;
	document.mainform.action = "/Mypage/insertimage/";
	document.mainform.submit();
}
function image_register(image_num) {
	document.getElementById('image_num').value = image_num;
	document.mainform.action = "/Mypage/registimage/";
	document.mainform.submit();
}
function video_delete(video_num) {
  if(window.confirm(video_num + "枚目を削除します。\n本当によろしいですか？\n")){
	document.getElementById('video_num').value = video_num;
	document.mainform.action = "/Mypage/deletevideo/";
	document.mainform.submit();
  }
}
function video_register(video_num) {
	document.getElementById('video_num').value = video_num;
	document.mainform.action = "/Mypage/registvideo/";
	document.mainform.submit();
}

function option_register() {
	document.mainform.action = "/Mypage/registoption/";
	document.mainform.submit();
}

function label_register() {
	document.mypage.action = "/Mypage/registlabel/";
	document.mypage.submit();
}

function preview() {
	window.open('', 'new', 'width=740, height=700, resizable=0, toolbar=0, status=0, menubar=0, location=0, directories=0, scrollbars=1');
	window.document.mainform.action = "/Preview/preview/";
	window.document.mainform.target = "new";
	window.document.mainform.method = "POST";
	window.document.mainform.submit();
	window.document.mainform.action = "/Mypage/updatemessage/";
	window.document.mainform.target = "";
}

function dateprinter() {
	var targetdate = new Date();
	targetdate.setDate((new Date()).getDate() + 10);
	document.write(targetdate.getMonth() + 1);
	document.write("月\n");
	document.write(targetdate.getDate());
	document.write("日\n");
}
