<form action="" id="post_form" method="post" onsubmit="query_send()">
</form>
function query_send(e){
var elem = document.getElementById('end');
var start = document.getElementById('start');
e.preventDefault();
post_ajax_(start,end);
function post_ajax_(start,end){
$.ajax({
url: '/server/make_letter.php',
type: "POST",
data: ({start:start,end:end}),
cache: false,
error: function (xhr, ajaxOptions, thrownError) {
/* alert(" write json item, Ajax error! " + xhr.status + " error =" + thrownError + " xhr.responseText = " + xhr.responseText ); */
},
success: function (data) {
console.log(data);
}
});
}
}