<!--
// Æû³» ¸ðµç °ªÀ» º¯¼ö=°ª&Çü½ÄÀ¸·Î ¸¸µé¾îÁØ´Ù.(ÇÊ¼ö)
function formData2QueryString(docForm) {
	var strSubmitContent = '';
	var formElem;
	var strLastElemName = '';	
	for (i = 0; i < docForm.elements.length; i++) {		
		formElem = docForm.elements[i];
		switch (formElem.type) {
			// Text fields, hidden form elements
			case 'text':
			case 'hidden':
			case 'password':
			case 'textarea':
			case 'select-one':
				strSubmitContent += formElem.name + '=' + escape(formElem.value) + '&'
				break;				
			// Radio buttons
			case 'radio':
				if (formElem.checked) {
					strSubmitContent += formElem.name + '=' + escape(formElem.value) + '&'
				}
				break;
				
			// Checkboxes
			case 'checkbox':
				if (formElem.checked) {
					// Continuing multiple, same-name checkboxes
					if (formElem.name == strLastElemName) {
						// Strip of end ampersand if there is one
						if (strSubmitContent.lastIndexOf('&') == strSubmitContent.length-1) {
							strSubmitContent = strSubmitContent.substr(0, strSubmitContent.length - 1);
						}
						// Append value as comma-delimited string
						strSubmitContent += ',' + escape(formElem.value);
					}else{
						strSubmitContent += formElem.name + '=' + escape(formElem.value);
					}
					strSubmitContent += '&';
					strLastElemName = formElem.name;
				}
				break;				
		}
	}	
	// Remove trailing separator
	strSubmitContent = strSubmitContent.substr(0, strSubmitContent.length - 1);
	return strSubmitContent;
}
// ³Ñ°ÜÁ® ¿Â°ª Ã³¸®(°øÅëÇÊ¼ö)
function xmlhttpPost(strURL, strSubmit, strResultFunc) {
	var xmlHttpReq = false;	
	/*
	if (window.XMLHttpRequest) {		//Win Mac Linux m1,f1,o8 Mac s1 Linux k3¿ë, Mozilla/Safari
		xmlHttpReq = new XMLHttpRequest();
		xmlHttpReq.overrideMimeType('text/xml');
	} else 
	*/
	if (window.ActiveXObject) {	// IE
		try {							//Win e4,e5,e6¿ë
			xmlHttpReq = new ActiveXObject("Msxml2.XMLHTTP") ;
		} catch (e) {
			try {
				return new ActiveXObject("Microsoft.XMLHTTP") ;
				xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
			} catch (e2) {
				xmlHttpReq = null;
			}
		}
	}
	xmlHttpReq.open('POST', strURL, true);
	xmlHttpReq.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
	xmlHttpReq.onreadystatechange = function() {
		if (xmlHttpReq.readyState == 4) {
			strResponse = xmlHttpReq.responseText;
			switch (xmlHttpReq.status) {			
				case 404:// Page-not-found error
					alert('Error: Not Found. The requested URL ' +
					strURL + ' could not be found.');
					break;			
				case 500:// Display results in a full window for server-side errors
					handleErrFullPage(strResponse);
					break;
				default:// Call JS alert for custom error or debug messages
					if (strResponse.indexOf('Error:') > -1 ||
						strResponse.indexOf('Debug:') > -1) {
							alert(strResponse);
						}else{// Call the desired result function
							eval(strResultFunc + '(strResponse);');
						}
						break;
					}
			}
		}
	xmlHttpReq.send(strSubmit);
}
// ¿¡·¯Ã³¸® ÇÊ¼ö-¼öÁ¤ÇÒ°Í
function handleErrFullPage(strIn) {
	var errorWin;	
	try {// display error
		errorWin = window.open('', 'errorWin','height=500,width=600');
		errorWin.document.body.innerHTML = strIn;
	}catch(e) {// If pop-up gets blocked, inform user
		alert('An error occurred, but the error message cannot be' +
		' displayed because of your browser\'s pop-up blocker.\n' +
		'Please allow pop-ups from this Web site.');
	}
}

//-->
