Can't upload pictures!
-
I need to fix this ASAP and I have no idea where to begin! Thanks in advance for any help.
I just launched my forum and I can't upload images anywhere. I've tried uploading them as avatars, in new topics, and in replies. I always get either "Error: Undefined" or "Error: 0" in a faded red popup.
Help me Obi Wan Kenobi; you are my only help. Thanks!
Aaron -
Did you create an imgur app and put your client id in the admin panel? Or did you enable file uploading from admin > settings > post? Also make sure you are on the latest code. And as @planner mentioned if you have any errors in your console post them here.
-
Thanks everyone! So here's the error:
info: NodeBB Ready
4567 0.0.0.0
info: [Auth] Session tLx5sgq86JqT-9qEM1ImdJ4y logout (uid: 1)
info: Attempting upload to: /var/www/forum/public/uploads/1-profileimg.jpg/var/www/forum/src/routes/user.js:218
winston.err(err);
^
TypeError: Object #<Object> has no method 'err'
at WriteStream.<anonymous> (/var/www/forum/src/routes/user.js:218:13)
at WriteStream.EventEmitter.emit (events.js:117:20)
at WriteStream.<anonymous> (fs.js:1655:12)
at Object.oncomplete (fs.js:107:15)Any ideas?
-
@baris Under admin > settings > post, I checked the box "Allow users to upload regular files" and I set the "Maximum File Size" to 5000, which I assume is in kb.
As for the imgur app, I thought I could just store the images in /public/uploads. That worked for me when I was hosting it locally. Is that not the case?Thanks!
Aaron