Welcome Guest, Not a member yet? Register   Sign In
File Upload - image too large (but its not?)
#1

[eluser]matt2012[/eluser]
Ive just moved some code to a new server and im getting an error using the file upload library saying the files im attempting to upload are too large. But there not.

Code:
$config['max_size']  = '500';
        $config['max_width']  = '2000';
        $config['max_height']  = '1000';

The error I get is..

Code:
The image you are attempting to upload is to large.

when I email myself the upload data I get..

Code:
a:13:{...s:9:"file_size";d:68.7000000000000028421709430404007434844970703125;...}

The file size here is right the odd thing is the number of decimals is this whats causing the bug and how would I sort this out?

cheers
#2

[eluser]pistolPete[/eluser]
Where do you get this error message from? It's not the CI standard one.
Quote:The image you are attempting to upload is to large.

Please do a var_dump() to see the real contents of the array instead of serializing the array.
#3

[eluser]WildPhoenix[/eluser]
It's strange you are getting a very long length of extra decial places. Have you tried various files?
#4

[eluser]pad2[/eluser]
Check the size of the image(size in kb or MB), if its too large also you can't able to upload. Upload a small image and check it out. I think there is no problem in the dimension.
#5

[eluser]matt2012[/eluser]
Dont know what the issue was but it appears to be solved - I deleted the directory it was being uploaded to and let it create another one.
#6

[eluser]visormatt[/eluser]
You may want to look into the PHP.ini settings as well. While reading another post I saw that many times this installation will have default limits set. Looks like you have it working, but just an FYI.




Theme © iAndrew 2016 - Forum software by © MyBB