<%@ page contentType="text/html; charset=utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="ui" uri="http://egovframework.gov/ctl/ui"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>


<script type="text/javaScript" language="javascript">
	$( document ).ready(function(){
	});
	
	function send(){
		$.ajax({
            url: '/web/xxx/xxxEmailAjax.do',
            type: 'POST',
            processData: false,
            contentType: false,
            data: new FormData(document.emailForm),
            success: function(response) {
				alert(response);
        		window.close();
            },
            error: function(error) {
            	alert("error");
            }
        });
	}
</script>


<form id="emailForm" name="emailForm" action="" method="post">
<div class="sub_content">
	<!-- page_location -->
	<div class="list_view">
		<div class="list_view_wrap">
			<h4 class="list_view_tit">
				메일발송 샘플
			</h4>
			<div class="view_content">
				수신자 :: <input type="text" id="receiver" name="receiver" class="text"/>
				</br>
				제목 :: <input type="text" id="subject" name="subject" class="text"/>
				</br>
				내용 :: <textarea rows="10" id="content" name="content" cols="30"></textarea>
			</div>

			<div class="btn_wrap right">
				<button type="button" class="btn btn_text btn_40 gray_fill" onclick="send();">발송</button>
			</div>
		</div>
	</div>
</div>
</form>