nodejs req请求参数
2017-01-26 本文已影响0人
恩行我的流量
req.parames.a /:a
req.query.a ?a=1
req.body.a
req.cookies.a
req.get('Content-Type'); // => "text/plain"
req.is(type)
req.accepts(types)
req.use(cookie-parser)
req.use(body-parser)
req.parames.a /:a
req.query.a ?a=1
req.body.a
req.cookies.a
req.get('Content-Type'); // => "text/plain"
req.is(type)
req.accepts(types)
req.use(cookie-parser)
req.use(body-parser)