create the web service by yourshelf

 

start cmd

node demo.js

var http = require('http');

http.createServer(function (request, response) {
  response.writeHead(200, {'Content-Type': 'text/plain'});
  response.end('good night\n');
}).listen(8888);

console.log('Server running at http://127.0.0.1:8888/');

 

 

http://nodejs.org/

posted @ 2014-12-28 22:16  fleam  阅读(163)  评论(0编辑  收藏  举报