Re: Pictureupload

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thursday 03 November 2005 19:12, twistednetadmin wrote:
My advise is not to use $_FILES['img']['type'] or use it with some switch 
statement.
Different browsers send different mime types for same image format. For 
example on mozila you have image/png on IE you have image/x-png (or vise 
versa)
Also the are different mimes for JPEG
image/jpg
image/jpeg
..........
image/gif
image/x-gif


You better see what is the type of the image when the error occurs.


> The errormessage is from this part of the script.
>
> echo "Result:<br>\n";
> echo "Now that didn't seem to work... <br>\n
> Did you try a wrong format or size? <br>\n
> File that failed--> (".$_FILES['guildimage']['name '].")<br>";
>
> So it seems that the file is wrong type or size, but as it works with the
> same picture from my own computer that is odd.
>
> The timeout part I have to check before I answer to, but I have 4mb
> connection and the last user it failed for has a 2mb connection. 300kb
> shouldn't make the script time out? Or could it? Where do I check the
> timeout settings btw? PHP.ini?
> Or can I run phpinfo() on it?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux