function doFormToJson(formname) {
	var _json = {};
	for (checki = 0; checki < formname.elements.length; checki++ ) {
		var el = formname.elements[checki];
		if (!el.name || el.disabled) return;
		var value = (el.tagName.toLowerCase() == 'select') ? Element.getSelected(el).map(function(opt){
				return opt.value;
			}) : ((el.type == 'radio' || el.type == 'checkbox') && !el.checked) ? null : el.value;
			$splat(value).each(function(val){
				if (typeof val != 'undefined') {
					if (typeof _json[el.name] == 'undefined') {
						_json[el.name] = val;
					} else {
						(_json[el.name] = $splat(_json[el.name])).push(val);
					}
				}
			});
	}
	return JSON.encode(_json);
}

/**
 * °øÅëÃ³¸®
 *
 * @param url     È£ÃâÇØ¾ß ÇÏ´Â URL
 * @param formid  ³Ñ°Ü¾ß ÇÏ´Â form ¸í ¶Ç´Â json-object
 * @param formdiv ¸®ÅÏ¹ÞÀº html Áß º¯°æÇØ¾ß ÇÏ´Â ¿µ¿ª
 * @param schfrm  ¸®ÅÏ¹ÞÀ» html ¿¡¼­ÀÇ °Ë»öÁ¶°Ç( form ¸í ¶Ç´Â json-object )
 */
 
function doAction(url, jsondata) {
	_req = new Request.JSON({url: url,
			evalScripts: false,
			onComplete: function(t,e,h,j) {
				retdata = e;
			}
		});
	_req.send(jsondata);
}

