Nemo

Nemo 关注TA

路漫漫其修远兮,吾将上下而求索。

Nemo

Nemo

关注TA

路漫漫其修远兮,吾将上下而求索。

  •  普罗旺斯
  • 负责帅就完事了
  • 写了1,495,102字

该文章投稿至Nemo社区   Js、Css、Html  板块 复制链接


【NodeJs】Http:post

发布于 2016/08/01 21:50 3,349浏览 0回复 807

var http = require('http');
var queryStr = require('querystring');
var util = require('util');

http.createServer(function (req,res){
        var post = '';
        req.on('data',function (chunk){
                post += chunk;
        });

        req.on('end',function (){
                post = queryStr.parse(post);
                res.end(util.inspect(post));
        });
}).listen(3000);

点赞(0)

上一个文章:【NodeJs】Http:client

下一个文章:【NodeJs】Http:get

点了个评