var http = require('http');
http.get({
host:'localhost',
path:'/user?name=Nemo',
port:'3000'
},function (res){
res.setEncoding('utf-8');
res.on('data',function (data){
console.log('服务器返回的数据为:'+data);
});
}
);
http.get({
host:'localhost',
path:'/user?name=Nemo',
port:'3000'
},function (res){
res.setEncoding('utf-8');
res.on('data',function (data){
console.log('服务器返回的数据为:'+data);
});
}
);