4images Forum & Community
Welcome, Guest. Please login or register.
Did you miss your activation email?
October 17, 2017, 03:21:11 PM

Login with username, password and session length
Search:     Advanced search
Togle to toolbar
Translate this page with =>
Translate this page >
* Home Help Search Login Register
 
+  4images Forum & Community
|-+  4images Help / Hilfe
| |-+  FAQ, Tips
| | |-+  Cannot upload large files (larger than 2Mb)
0 Members and 2 Guests are viewing this topic. « previous next »
Pages: [1] 2 3 4 » »» Print
Author Topic: Cannot upload large files (larger than 2Mb)  (Read 153153 times)
Chris
4images Moderator
4images Guru
*****
Offline Offline

Posts: 4487

Thank You
-Given: 0
-Receive: 31

Did u ever stop to think and then forget to start?


View Profile
« on: March 17, 2005, 04:15:49 AM »

Quote  [Expand]
I´ve got a problem uploading images or files larger than 2 MB. i have changed the image size in the settings but I still can´t upload more than 2 MB - it doesn´t even give me an error message. Does anyone have an idea of what could be wrong?

This is a limitation of your server's PHP configuration.  2Mb is the default upload file size limit when PHP is installed on a web server.  Only your hosting provider can change this setting inside php.ini

The other option is to first upload the file via FTP and then use the "Check New Images" function inside the admin control panel

[UPDATE]
Thanks to techmob for additional info on this topic.

The following settings in php.ini affect files upload:
Quote  [Expand]
file_uploads
1 to accept file uploads, 0 to not accept file uploads. Defaults to 1.


post_max_size
This is the maximum size of a POST request that PHP will accept. The default for PHP 4.3.x is 8M. If the file(s) you are trying to upload have a single or combined size over this value, PHP will exit. This affects the total post data. For example, if this were set to 8M and you are uploading four 3M files, PHP would not accept the files. You could, however, upload the four 3M files individually without a problem from this setting.


upload_max_filesize
This is the maximum size of an individual uploaded file. The default for PHP 4.3.x is 2M.


max_input_time
This is the maximum time PHP will accept input in seconds. The default for PHP 4.3.x is 60.

If you have access/persmission to modify settings directly in php.ini, do that, but if you can't do that AND your server is using Apache or other type of server that support .htaccess then you can insert the following into .htaccess in your gallery:
1
2
3
4
php_flag file_uploads on
php_value post_max_size "8M"
php_value upload_max_filesize "2M"
php_value max_input_time "60"
Change the values to satisfy your needs Wink
« Last Edit: September 01, 2006, 12:52:11 AM by V@no » Logged

V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
*****
Offline Offline

Posts: 17849

Thank You
-Given: 47
-Receive: 565

mmm PHP...


View Profile WWW
« Reply #1 on: March 24, 2005, 02:37:56 PM »

Another possible sollution is add
1
php_value upload_max_filesize "8M"
into .htaccess file into your 4images root dir. (in this case it should change the max upload size to 8mb

Note, that this method is not 100% guaranteed working.
Logged

Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)
whoopiedoo2
Newbie
*
Offline Offline

Posts: 28

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #2 on: August 03, 2005, 01:53:03 AM »

where do i upload the images to when doing it with ftp?
Logged
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
*****
Offline Offline

Posts: 17849

Thank You
-Given: 47
-Receive: 565

mmm PHP...


View Profile WWW
« Reply #3 on: August 03, 2005, 02:26:32 AM »

Please continue read FAQ, you almost there Razz

P.S. this makes wonder, what in this topic made u ask such unrelated to the topic question?
Logged

Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)
Jdm
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #4 on: February 17, 2006, 10:26:38 AM »

Hi dear friends.
I have been reading this whole week about this "2Mb image problem" and I tryed everything I could.

1. My server provided me a file php.ini where I changed the max file to 15 MB
* Nothing changed...

2.I tryed to make  the htaccess file with:
php_value upload_max_filesize "15M" inside.
* the page gets offline with this error message:
Internal Server Error
The server encountered an internal error or misconfiguration and was
unable to complete your request.
Please contact the server administrator, webmaster@yoursite.com and inform
them of the time the error occurred, and anything you might have done that
may have caused the error.  Shocked

3 I removed the .htaccess and everything came back to normal again. Rolling Eyes

This is what my server told me aboout .htaccess:

That's because of phpsuexec, which is incidentially the reason why the php.ini thing works.
More on that subject here:
http://ion-web.com/forum/showthread.php?t=3D1053

So, yank that out of the .htaccess, as it won't work.  The php.ini thing should work for you though, just copy the file over.

4.My server Checked out the upload_max_filesize listed on my site
with test.php:


It's currently set to 15 megabytes.  That's what it should be, which would indicate that the problem lies not with PHP but perhaps with something else.

5 Do you have any idea of what possibly is going on? Because neither I nor the server knows ??

Thank you for any help Embarassed



Logged
Acidgod
4images Moderator
4images Guru
*****
Offline Offline

Posts: 2420

Thank You
-Given: 0
-Receive: 1

It's me?


View Profile WWW
« Reply #5 on: February 17, 2006, 01:19:07 PM »

If you can use your own php.ini you must put the custom php.ini in each Folder where the Script is need the changes...

I think is it not enough to put the custom php.ini in the root Folder, then i think the custom php.ini has no recursive effekt...

I hope you understand my bad english... *g*

Logged

Jdm
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #6 on: February 17, 2006, 02:32:15 PM »

Thanks! I will try this Smile
No problem with your english. It is not my first language either  Mr. Green
Logged
Jdm
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #7 on: February 19, 2006, 04:20:30 PM »

Nope it doesnt work Sad

I put the php.ini file EVERYWHERE but nothing happens Sad
I put on the data directory, media, all the folders!
Nothing really!

Please could you try to think of something else I could try to do?
This is really making me nuts!

Logged
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
*****
Offline Offline

Posts: 17849

Thank You
-Given: 47
-Receive: 565

mmm PHP...


View Profile WWW
« Reply #8 on: February 19, 2006, 07:31:18 PM »

A link to your phpinfo could help Wink (refer FAQ for more info)
Logged

Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)
Acidgod
4images Moderator
4images Guru
*****
Offline Offline

Posts: 2420

Thank You
-Given: 0
-Receive: 1

It's me?


View Profile WWW
« Reply #9 on: February 20, 2006, 05:24:00 PM »

I put on the data directory, media, all the folders!

Not in the data Folder... (o:

You must put them in the Script Folder...

Like this:
/php.ini
/includes/php.ini
/admin/php.ini
Logged

Jmello
Newbie
*
Offline Offline

Posts: 17

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #10 on: February 20, 2006, 09:06:57 PM »

My php :

http://www.brassar.se/galleria/test/test.php

I am very ashamade to say this, but it didnt worked Sad
Please... Is there anything else I could do?  Crying or Very sad
Logged
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
*****
Offline Offline

Posts: 17849

Thank You
-Given: 47
-Receive: 565

mmm PHP...


View Profile WWW
« Reply #11 on: February 21, 2006, 12:38:19 AM »

So, how big where the files you tested with? 2mb? 3mb? what is the max size you CAN upload?
Logged

Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)
Jdm
Newbie
*
Offline Offline

Posts: 26

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #12 on: February 21, 2006, 02:15:59 AM »

1,107 is the heaviest so far  Embarassed
Logged
Jmello
Newbie
*
Offline Offline

Posts: 17

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #13 on: February 22, 2006, 03:22:59 PM »

I am trying a 3 MB file.. Doesnt work.. Just via ftp Neutral
Logged
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
*****
Offline Offline

Posts: 17849

Thank You
-Given: 47
-Receive: 565

mmm PHP...


View Profile WWW
« Reply #14 on: February 24, 2006, 02:05:40 AM »

Ok, lets test it, shall we? Wink
In member.php find:
1
if ($action == "uploadimage") {
Insert below:
1
2
echo "<pre>";
print_r($HTTP_POST_FILES);

Then upload a small file, then a big file and post the text that should be showed on top of the page for both files. (disregard any warning messages that may appier as well)
Logged

Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)
Pages: [1] 2 3 4 » »» Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.299 seconds with 19 queries.