$(function()
{
	$("#frmEntry").submit(function()
	{
		var j = zen_make_params("frmEntry");
		$.post(
			this.action,
			{
				"data" : j,
				"cmd-entry" : 1
			},
			function(ret)
			{
				if (ret.status == "SUCCESS")
				{
					location.href = "confirm.html";
				}
				else
				{
					alert(ret.status);
				}
			},
			"json"
		);
		return false;
	});
	
	$("#frmQuit").submit(function()
	{
		var j = zen_make_params("frmQuit");
		$.post(
			this.action,
			{
				"data" : j,
				"cmd-quit" : 1
			},
			function(ret)
			{
				if (ret.status == "SUCCESS")
				{
					location.href = "qthanks.html";
				}
				else
				{
					alert(ret.status);
				}
			},
			"json"
		);
		return false;
	});
});
