0
流星1.2铁路由器流星1.2,this.request.body是空
Router.route('/upload', {
where: 'server',
action: function(){
console.log(this.request.body);
this.response.end(JSON.stringify(this.request.body));
}
});
我正在使用前面提到issues线。
if (Meteor.isServer) {
Router.onBeforeAction(Iron.Router.bodyParser.urlencoded({
extended: false
}));
}
答案仍然是{}。这与流星1.2打破了吗?现在有什么解决方案?
这只是为我节省了很多时间。这段代码非常重要,很有趣,很难找到。谢谢! – jremi