Uploaded Images are distorted Uploaded Images are distorted
 

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

Uploaded Images are distorted

Started by moniko, May 16, 2004, 04:56:41 PM

Previous topic - Next topic

0 Members and 3 Guests are viewing this topic.

moniko

Hi,

I have just installed cpg 1.2.1 standalone and things seem to be working ok.  However, whenever i upload an image, jpeg, tiff or png the image thumbnail, normal and intermediate images are all distorted badly, usually beyond recognition.  This happens regardless of using GD 1, GD 2 or ImageMagick.  If anyone has any ideas please let me know. I have attached an example image.

Thanks,

Moniko


[attachment deleted by admin]

Joachim Müller

this is usually an indication that the pics you uploaded are broken. Make sure to use pics that are known-good (at least before upload). If the pics are to large, this may happen during upload. Please post a link to your page (and a non-admin test user account with upload privileges, if necessary).

GauGau

moniko

The pictures that im posting seem to be fine, they can be viewed with GQView and Gimp without any problems.  They are mostly images straight from a digital camera.
Here is a account you can log on with:

L: temp
P: hau3200qub

thanks for your help

moniko


Casper

I checked, and your originals are corrupted.  For instance, here is one;
(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fwww.e-globe.dynu.net%2Fcpg%2Falbums%2Fuserpics%2F10001%2Fnormal_1-300zx.04.jpg&hash=1d08065f9116c283d2a1e0cc2e82c8a140e66140)

This is the original, not the 'normal_' or 'thumb_'.

Coppermine does not alter the original, so they have been corrupted on upload. 
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

moniko

I checked that, the originals are fine.  Ill post the original of that image.  The images are only distorted after aupload, a batch upload works fine.  Here is the original of the eclips_spyder_main.jpg.
I have also manually done a convert on the image with ImageMagick from the command line and it worked fine.  Im not to sure of the upload process so i dont know what else to try.

Thanks again for your help


[attachment deleted by admin]

Joachim Müller

#6
tested this by uploading a known-good pic (very small) to your page: the image got corrupted as well. Imo this is related to your server settings or modifications (if any) done to coppermine's upload files.
Recommeded steps: get a fresh copy of the coppermine files and overwrite the ones on your server (to make sure the coppermine files themselves aren't corrupt).
If the server is yours to administer, check php.ini and webserver config (apache.conf or similar) and report any anomalies or stuff you changed from default settings.
There's something fishy with your server vars as well: hit the pic-info toggle to display pic info of any pic you uploaded: you'll notice that the url at the bottom displays http://127.0.0.1/cpg//displayimage.php?pos=-346 instead of http://www.e-globe.dynu.net/cpg/displayimage.php?pos=-346
Go to coppermine config and check what you have for "Target address for the 'See more pictures' link in e-cards" (this is more important than it looks).

GauGau

Joachim Müller

These server settings might need changes (php.ini):
upload_max_filesize  = 2MB;
max_execution_time = 30     ; Maximum execution time of each script, in seconds
max_input_time = 60        ; Maximum amount of time each script may spend parsing request data
memory_limit = 8M      ; Maximum amount of memory a script may consume (8MB)


GauGau

moniko

#8
first i would like to say thanx for your help.  I have changed all those settings to exceed amounts needed, i.e. 16M uploads and 300 for time limits but it still isnt working.  I assume that this is a php problem, do you know a good site i could post on?  thanx again

www.e-globe.dynu.net/phpinfo.php

Joachim Müller

I suggest you remove your phpinfo file, since it may make your more vulnerable to attacks.
I'm sorry I can't recommend any good sites on server setup and configuration, I usually google my way around ;)

GauGau

moniko

Ill keep looking. This is very frustrating i must say.  Thanx for your time.

sporkit

#11
ive had the same problem for a long time now.  i remember i posted a question similar to this in the old forum.  basicly everything worked fine while i had my win2k server up and running.  then i upgraded to fedora core 1 which has recent versions of mysql, php, and imagemagick.  my old 1.1 version of coppemine debug told me imagemagick wasnt recieving the entire file.  php has its limits high enough and so does my httpd config file.

the entire files just not making it and i have no idea what it is.  ???

also here is my link http://www.f8klan.com/cpg

sporkit

for quite awhlie i though that this was a problem with the linux server i built myself (i had this problem even back in the old forum).  however recently i had the chance to build my own picture upload script using the same files and everything works perfectly.  i think most of the people who experiance this problem (which is a few i found with google) are uploading across a lan connection.

users can upload to my site fine but if im sitting in my basement next to my webserver and upload, then the pictures are corrupt.  as i said before i thought this was my webservers fault till made my own script.  is it possible that whatever programming used in cpg isnt able to handle the file being sent as fast as it is and therefore starts resizing images to early or something?

i dont know just a though.  i guess im just saying the problem isnt with users webservers.

Tranz

Quote from: sporkit on September 22, 2004, 07:32:45 AM
users can upload to my site fine but if im sitting in my basement next to my webserver and upload, then the pictures are corrupt. as i said before i thought this was my webservers fault till made my own script. is it possible that whatever programming used in cpg isnt able to handle the file being sent as fast as it is and therefore starts resizing images to early or something?
I have Coppermine installed on my local computer and when I "batch upload", it's not even really uploading because the files are coming from the same computer. So, the theory that "CPG isn't able to handle the file being sent as fast as it is" just doesn't jibe with reality, since the files aren't even being sent to another computer in my case.

Joachim Müller

neither ftp nor transport over a LAN should modify your files. I use coppermine on an intranet, doing uploads over a LAN connection works fine.

Joachim