Jump to content

Recommended Posts

Posted

Hi,

For the first time, I'm having trouble with the file uploader when uploading large files on our staging server.

I've got this in the main .htaccess

php_value upload_max_filesize 301M
php_value post_max_size 301M

But, when I upload a file of about 17MB or so, the progress bar stops at anywhere between 96 and 99%.

Guessing it's the ajax uploader, but not sure if there's a way to disable it or workaround it.

Thanks.

Posted

Is there some specific file size where this fails? I am thinking about possibility to automatically fallback to traditional upload when files are 15MB or larger. Although we need to first try to find the reason and fix for this.

Posted

I'm using FF 7.01 on the Mac. Just tested some more now and found that a 4MB file worked, but a 7MB stalled at 99% - so somewhere in there seems to be the trouble.

Posted

Thanks for the tip, Nico. I've used the same hack you did to enable the oldSchool upload. Works for now, but I miss the slick drag and drop for sure :)

Posted

By the way. I had/still have the same problem on my schools website. If the drag'n'drop file is too huge I can't use drag and drop and have to use the default old way. I don't know why this is like it is...

  • 8 months later...
Posted

Hi everyone,

I face same problem with file upload. The ajax processed small file without a problem (around 3MB), but when it is time for large files (greater than 6MB) it stalls at 99%. FF console outputs error 'JSON.parse: unexpected character'.

My share hosting limits at Hostgator

safe mode = Off (cannot adjust)

memory_limit = 256M (MAXIMUM)

max_execution_time = 30 (MAXIMUM in seconds)

max_input_time = 60 (MAXIMUM in seconds)

post_max_size = 64M (MAXIMUM)

upload_max_filesize = 64M (MAXIMUM)

enable_dl = Off (cannot adjust)

File is below 64MB limit. What could it be?

Posted

I'm not sure what it could be, but I think it would be worth trying another browser just in case it's client side. Since you are using FF, try it in Chrome just to see if it makes any difference. What is the exact size of the file you are uploading? I can try to find something similar here to test with.

Posted

Result of 50MB file upload via InputfieldFile

---------Firefox upload test-----------------------------------------------------------

Progress bar stalls at 99%

---------Console output-----------

[22:28:41.797] SyntaxError: JSON.parse: unexpected character @ .../wire/modules/Jquery/JqueryCore/JqueryCore.js?v=162:16

----------PHP error log----------

[00:28:41] PHP Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 50000001 bytes) in Unknown on line 0

[00:30:10] PHP Warning: Unknown: open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (/home/pws/:/home/pws/store/openssl/) in Unknown on line 0

[00:30:10] PHP Warning: File upload error - unable to create a temporary file in Unknown on line 0

---------Chrome upload test------------------------------------------------------------

Progress bar stalls at 100%

---------Console output-----------

Failed to load resource: the server responded with a status of 404 (Page Not Found)

Uncaught SyntaxError: Unexpected token < JqueryCore.js:16

e.extend.parseJSON JqueryCore.js:16

$.parent.each.fileData InputfieldFile.js:171

----------PHP error log----------

[01:15:41] PHP Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 50000001 bytes) in Unknown on line 0

--------IE upload test------------------------------------------------------------

Upload doesn't begin; Ajax doesn't function.

  • Like 1
Posted

I've set memory_limit same as post_max_size and upload_max_filesize to recreate the case on test server. In conclusion, memory_limit is the cause of upload failure. Memory_limit should be increased to accommodate upload and other functions. It is why small files upload just fine, but large files not. Problem solved. :)

  • Like 2
  • 5 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...