News:

Wondering if this will always be free?  See why free is better.

Main Menu

Cannot upload attachments

Started by WolfLust, February 23, 2008, 02:11:08 AM

Previous topic - Next topic

WolfLust

Dear All,

I have all the settings correct in my forum and yet I cannot upload attachments can anyone please advise?

I tried to chmod the /forum/attachments directory to 777, 755, 744 and that didn't help fix it. I also tried to change the option in: Admin -> Packages -> Options to All files are writable. and that didn't fix it.

If it may be helpful here's my phpinfo: http://metalje.com/phpinfo.php

I have SMF 1.1.4 and Ancient and Rusted as a theme.

What is phpinfo.php?
For the great day of wrath is coming, and who shall be able to stand?

cryptodan

Does this happen with all files or just certain files of certain size and extension?

WolfLust

I tried posting pictures with extensions within the allowed list of SMF's administration, and with small sizes (less than 100Kbs) although the size allowed in the forum's administration is 10mbs

Thank you for your reply
For the great day of wrath is coming, and who shall be able to stand?

greyknight17

Does it stay at 777 when you CHMOD it? Go back and verify the permissions.

I have seen cases where the path is wrong. Use repair_settings.php and confirm that all your paths are correct. If incorrect, click on the Recommended values and it should fix it up for you. Save it and then delete this file. See if they work now.

WolfLust

Thank you for your reply.

Yes the directory and all the files are set to 777.

And I used the repair_settings.php file and the paths are correct.

Does my phpinfo.php say anything?

Thanks.
For the great day of wrath is coming, and who shall be able to stand?

greyknight17

Were you ever able to upload attachments before at all? If so, did you make any changes to the forum before this problem occurred?

The phpinfo.php file looks ok. It shouldn't give you problems especially when you upload smaller files like 100kb (as you said earlier).

cryptodan

I would check to make sure that you do not have any size limits.  I just tried uploading a 4kilobyte file, and got the below:

Your attachment couldn't be saved. This might happen because it took too long to upload or the file is bigger than the server will allow.

Please consult your server administrator for more information.

greyknight17

If you get that error, it's not because of a size limitation. Make sure that your attachments is writable and that the path is correct.

WolfLust

Thank you for your replies everyone.

I could never upload an attachment before and the path is correct. This seems strange.
For the great day of wrath is coming, and who shall be able to stand?

greyknight17

Is your avatars directory writable? See if it's already 755. If not CHMOD it to 755.

WolfLust

Thank you for taking the time to reply greyknight17.

I just tried to chmod -R 777 and 755 attachments/ and that didn't solve the problem although the directory and the files were successfully changed.
For the great day of wrath is coming, and who shall be able to stand?

greyknight17


cryptodan

Can the user that is being ran as the webserver write to your directory?

WolfLust

greyknight17 I changed the permissions for both the avatars dir and the attachments dir to 755, with and without -R

The attachments directory in the Admin -> Attachments & Avatars -> Attachments Settings -> Attachments directory is RED, is this normal? I try to change it to the automatically detected path, which is correct, and also changed it to http://www.metalje.com/forum/attachments and still didn't work.

dan502 can you please elaborate?

Thank you again.
For the great day of wrath is coming, and who shall be able to stand?

greyknight17

No. Red usually means incorrect path. Can you verify the same thing for Avatars (make sure it's the correct path)? You can use repair_settings.php to check them all just to confirm. Then delete the file when done.

WolfLust

Thank you for replying greyknight17.

The red path in the admin section, is the same path detected by the repair_settings.php file.
For the great day of wrath is coming, and who shall be able to stand?

metallica48423

path != URL.

It should not be a URL, but a path.  ie /home/user/etc...

if it is red, then it can't find the path.
Justin O'Leary
Ex-Project Manager
Ex-Lead Support Specialist

QuoteMicrosoft wants us to "Imagine life without walls"...
I say, "If there are no walls, who needs Windows?"


Useful Links:
Online Manual!
How to Help us Help you
Search
Settings Repair Tool

WolfLust

Thank you for replying.

The paths are no longer red, however, I still can't upload anything. Not even a small (allowed) txt file.
For the great day of wrath is coming, and who shall be able to stand?

metallica48423

have the errors changed at all?  Any error log entries?  what is the path set as, and, are the permission on it correct?
Justin O'Leary
Ex-Project Manager
Ex-Lead Support Specialist

QuoteMicrosoft wants us to "Imagine life without walls"...
I say, "If there are no walls, who needs Windows?"


Useful Links:
Online Manual!
How to Help us Help you
Search
Settings Repair Tool

WolfLust

permission is 777, and the path is correct now.

The error's still the same.

Thanks for replying.
For the great day of wrath is coming, and who shall be able to stand?

Advertisement: