Upload problem Upload problem
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Upload problem

Started by lazlo, January 23, 2019, 04:50:10 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

lazlo

Just upgraded to 1.6x on 1&1 (Ionos now) since they require PHP 7.2  and everything seems to be working with the exception of uploading pictures. I always get a message: "File is larger than max size allowed." even though I set the sizes to default recommended. Even if I try to upload a 10kb file I get the same message. Would you mind giving me some ideas how to fix this ?

lazlo

Quote from: lazlo on January 23, 2019, 04:50:10 PM
Just upgraded to 1.6x on 1&1 (Ionos now) since they require PHP 7.2  and everything seems to be working with the exception of uploading pictures. I always get a message: "File is larger than max size allowed." even though I set the sizes to default recommended. Even if I try to upload a 10kb file I get the same message. Would you mind giving me some ideas how to fix this ?

I realize that when I choose single file upload I can upload one picture at a time. Still no luck with HTML5 or Flash

phill104

While this section of the docs needs updating, most of it is still pertinent - http://documentation.coppermine-gallery.net/en/upload_troubleshooting.htm

If you could do as suggested in that section, providing a link and a test account etc, then it will make diagnoses a lot easier.
It is a mistake to think you can solve any major problems just with potatoes.

lazlo

 Thank you Phill
http://www.housatoniccameraclub.com/gallery/

Username: tester
    Password: tester
album: test

ron4mac

You need to adjust your php.ini. Make sure that upload_max_filesize, post_max_size and memory_limit are set to a large enough value. For an image gallery, 16M, 32M and 256M, respectively, would be okay settings. And in the CPG config File Settings you need to set a value greater than 1M for file uploads.

lazlo

I wonder if that is where the problem lies since I can upload the same file with single upload , but I cannot even upload a 10kb file with HTLM5 or Flash

lazlo

Quote from: lazlo on January 24, 2019, 01:46:07 AM
I wonder if that is where the problem lies since I can upload the same file with single upload , but I cannot even upload a 10kb file with HTLM5 or Flash
Just wanted to add that the  upload_max_filesize, post_max_size are both set at 64MB  and memory_limit is set at 256MB

ron4mac

Are you seeing the from the phpinfo menu item in your gallery?

lazlo

Yes, here is a screenshot:

ron4mac

You need to set the size in Config -> File settings -> Max size for uploaded files. Even if it looks okay, change its setting and save the config.

lazlo

I changed it to 1 gig but same problem. It has to be something else

ron4mac

Quite strange!!  You'll have to give me some greater access to your site. We can start with an admin account for your gallery (PM me with login). If that doesn't help find a solution, you may have to give me access to your files (I'll give you something to make that simple).

ron4mac

The problem comes from the fact that your php memory_limit is set to -1 (I wasn't aware it could be).

In the file plugins/upload_h5a/initialize.inc.php, change line 41:
$this->sys_max_chnk_size = min($this->to_bytes(ini_get('upload_max_filesize')), $this->to_bytes(ini_get('post_max_size')), $this->to_bytes(ini_get('memory_limit')));
to:
$this->sys_max_chnk_size = min($this->to_bytes(ini_get('upload_max_filesize')), $this->to_bytes(ini_get('post_max_size')));

That should take care of your issue. Changes will be made to keep it from being an issue in the future.

lazlo

Thank you Ron, this worked
Lazlo