|
|
|
14년 전
|
조회 990
|
|
|
|
14년 전
|
조회 1,709
|
|
|
|
14년 전
|
조회 2,806
|
|
|
|
14년 전
|
조회 2,055
|
|
|
|
14년 전
|
조회 2,113
|
|
|
|
14년 전
|
조회 1,527
|
|
|
|
14년 전
|
조회 1,338
|
|
|
|
14년 전
|
조회 1,239
|
|
|
|
14년 전
|
조회 1,010
|
|
|
|
14년 전
|
조회 482
|
|
|
|
14년 전
|
조회 1,399
|
|
|
|
14년 전
|
조회 4,487
|
|
|
|
14년 전
|
조회 1,365
|
|
|
|
14년 전
|
조회 1,140
|
|
|
|
14년 전
|
조회 630
|
|
|
|
14년 전
|
조회 867
|
|
|
|
14년 전
|
조회 683
|
|
|
|
14년 전
|
조회 577
|
|
|
|
14년 전
|
조회 651
|
|
|
|
14년 전
|
조회 628
|
|
|
|
14년 전
|
조회 575
|
|
|
|
14년 전
|
조회 1,449
|
|
|
|
14년 전
|
조회 770
|
|
|
|
14년 전
|
조회 630
|
|
|
|
14년 전
|
조회 598
|
|
|
|
14년 전
|
조회 645
|
|
|
|
14년 전
|
조회 944
|
|
|
|
14년 전
|
조회 844
|
|
|
|
14년 전
|
조회 1,445
|
|
|
|
14년 전
|
조회 1,058
|
|
|
|
14년 전
|
조회 3,515
|
|
|
|
14년 전
|
조회 747
|
|
|
|
14년 전
|
조회 1,293
|
|
|
|
14년 전
|
조회 1,024
|
|
|
지운아빠
|
14년 전
|
조회 2,766
|
|
|
|
14년 전
|
조회 2,372
|
|
|
|
14년 전
|
조회 574
|
|
|
|
14년 전
|
조회 1,634
|
|
|
|
14년 전
|
조회 579
|
|
|
|
14년 전
|
조회 2,381
|
|
|
|
14년 전
|
조회 1,930
|
|
|
|
14년 전
|
조회 546
|
|
|
|
14년 전
|
조회 5,626
|
|
|
|
14년 전
|
조회 903
|
|
|
|
14년 전
|
조회 1,404
|
|
|
|
14년 전
|
조회 1,223
|
|
|
|
14년 전
|
조회 1,257
|
|
|
|
14년 전
|
조회 1,150
|
|
|
|
14년 전
|
조회 1,141
|
|
|
|
14년 전
|
조회 985
|
|
|
|
14년 전
|
조회 1,327
|
|
|
|
14년 전
|
조회 1,730
|
|
|
|
14년 전
|
조회 730
|
|
|
|
14년 전
|
조회 1,112
|
|
|
|
14년 전
|
조회 2,153
|
|
|
|
14년 전
|
조회 1,999
|
|
|
관리자
|
14년 전
|
조회 957
|
|
|
|
14년 전
|
조회 1,446
|
|
|
관리자
|
14년 전
|
조회 3,939
|
|
|
|
14년 전
|
조회 678
|
|
|
|
14년 전
|
조회 2,658
|
|
|
|
14년 전
|
조회 1,422
|
|
|
|
14년 전
|
조회 1,870
|
|
|
|
14년 전
|
조회 1,082
|
|
|
|
14년 전
|
조회 852
|
|
|
똥싼너구리
|
14년 전
|
조회 846
|
|
|
관리자
|
14년 전
|
조회 1,000
|
|
|
|
14년 전
|
조회 1,071
|
|
|
|
14년 전
|
조회 1,956
|
|
|
|
14년 전
|
조회 3,199
|
|
|
관리자
|
14년 전
|
조회 2,250
|
|
|
|
14년 전
|
조회 962
|
|
|
|
14년 전
|
조회 1,571
|
|
|
|
14년 전
|
조회 1,823
|
|
|
|
14년 전
|
조회 624
|
|
|
|
14년 전
|
조회 1,851
|
|
|
|
14년 전
|
조회 3,091
|
|
|
|
14년 전
|
조회 1,773
|
|
|
|
14년 전
|
조회 2,719
|
|
|
|
14년 전
|
조회 4,013
|
|
|
|
14년 전
|
조회 4,067
|
|
|
|
14년 전
|
조회 2,467
|
|
|
|
14년 전
|
조회 894
|
|
|
|
14년 전
|
조회 1,194
|
|
|
|
14년 전
|
조회 4,018
|
|
|
|
14년 전
|
조회 2,329
|
|
|
|
14년 전
|
조회 1,484
|
|
|
|
14년 전
|
조회 3,863
|
|
|
|
14년 전
|
조회 2,531
|
|
|
|
14년 전
|
조회 615
|
|
|
|
14년 전
|
조회 2,527
|
|
|
|
14년 전
|
조회 670
|
|
|
|
14년 전
|
조회 898
|
|
|
|
14년 전
|
조회 1,731
|
|
|
|
14년 전
|
조회 1,353
|
|
|
|
14년 전
|
조회 1,608
|
|
|
|
14년 전
|
조회 1,165
|
|
|
|
14년 전
|
조회 2,176
|
|
|
|
14년 전
|
조회 846
|
|
|
|
14년 전
|
조회 848
|
댓글 3개
express.js 가 node에서 http를 쉽게 처리할수 있도록 해주는 라이브러리입니다.
app.get("/page/", function(req, res) {
console.log('request userid : ' + req.params.userid);
}
대충 이런식
현제 전송방식은
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=euc-kr" />
<title>Ajax Test</title>
<script language="Javascript">
/*http://blog.naver.com/ctlim2?Redirect=Log&logNo=50044001483*/
/**
* Ajax Call
* @param strURL : call cgi
* @param strFunction : callBack Function
* @param strArgument : argument
*/
function xmlhttpPost(strURL, strArgument, callFunction) {
var xmlHttpReq = false;
var self = this;
// Mozilla/Safari
if(window.XMLHttpRequest) {
self.xmlHttpReq = new XMLHttpRequest();
}
// IE
else if(window.ActiveXObject) {
self.xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
}
self.xmlHttpReq.open('GET', strURL, true);
self.xmlHttpReq.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded; charset=UTF-8');
self.xmlHttpReq.onreadystatechange = function() {
if(self.xmlHttpReq.readyState == 0) { // 아직 초기화 안됨
}
else if(self.xmlHttpReq.readyState == 1) { // 읽는 중
}
else if(self.xmlHttpReq.readyState == 2) { // 읽기 완료
}
else if(self.xmlHttpReq.readyState == 3) { // 작업 중
}
else if(self.xmlHttpReq.readyState == 4) { // 작업완료
callFunction(self.xmlHttpReq);
}
}
self.xmlHttpReq.send(strArgument);
}
/**
* callBack Json
*/
function callBackJson(in_Data){
// JSON 일 때
var arrayDoc = in_Data.responseText;
eval("var jsonData ="+arrayDoc);
//var text = jsonData['id'];
//document.getElementById("result").innerHTML = text;
document.getElementById("result").innerHTML = in_Data.responseText
}
/**
* Ajax Json을 호출 한다.
*/
function callJson()
{
var form = document.forms['f1'];
var id = form.id.value;
var a = form.a.value;
var b = form.b.value;
var id = encodeURIComponent(id);
var a = encodeURIComponent(a);
var b = encodeURIComponent(b);
xmlhttpPost('http://terrorboy.net:40000', "id="+id+"&a="+a+"&b="+b, callBackJson);
}
</script>
</head>
<body>
<form name="f1" accept-charset="">
id: <input id="id" name="id" type="text" value="id" /> <br />
a: <input id="a" name="a" type="text" value="a" /> <br />
b: <input id="b" name="b" type="text" value="b" /> <br />
<input value="Json" type="button" onclick="JavaScript:callJson()" />
<div id="result"></div>
</form>
</body>
</html>
입니다 ㅎㅎ