Alanaktion / phproject

A high performance full-featured project management system
https://www.phproject.org
GNU General Public License v3.0
384 stars 106 forks source link

can't upload pdf files to a project #411

Closed jonium closed 2 years ago

jonium commented 2 years ago

Hello, I can upload files of other extensions but pdf. Is there a list of allowed extensions?

Alanaktion commented 2 years ago

There are some file types that are blocked, but PDFs are definitely allowed. You are most likely being limited by file size rather than type, PHP by default limits files to only 2 MB on most installations. Check your upload_max_filesize and post_max_size settings in php.ini, and also check the file size setting limit in the site configuration.

If you're using nginx, there is also a limit on request body size there that can be adjusted with the client_max_body_size value as shown in the nginx-example.conf configuration file.

jonium commented 2 years ago

The Pdf file size is 4 Mb and I see that other pdf files were uploaded. I'm using Apache, upload_max_filesize and post_max_size are 64M. I thought it maybe modsecurity, disabled it and same situation, no errors neither in any log and at screen

jonium commented 2 years ago

The problem is definitely of size, I trid with a 34k pdf and it get uploaded

jonium commented 2 years ago

is there any size limit in the app code?

Alanaktion commented 2 years ago

There is a limit set in the Phproject configuration, you can adjust it from the Administration > Configuration page, in the Advanced tab.

jonium commented 2 years ago

Thanks, trying to change it I get "No attribute specified."

jonium commented 2 years ago

I change it from the db