Object # has no method 'forEach'
回复 (6)
A
forEach是Array的方法,你是对对象使用了这个方法吧。
X
引用 airylandforEach是Array的方法,你是对对象使用了这个方法吧。
是的 Post.get(null, function(err, posts) { if (err) { posts = []; } res.render('index', { "title": '首页', "posts": posts, });
});
X
引用 airylandforEach是Array的方法,你是对对象使用了这个方法吧。
@xuygfbi 在<% if (!user) { %>
Y
引用 airylandforEach是Array的方法,你是对对象使用了这个方法吧。
@xuygfbi 怎么解决的?亲
N
cnodejs bug啊,用户的输入没有进行编码就直接输出到html了。。。
L
跟我一样的亲手可以参考哦 http://www.9958.pw/post/nodejs_lesson
参与回复
登录后即可参与回复。登录