Who can help? In order to be able using down-sozed versions of my high-resolution photos, i stored them on my server space, and use a PHP script to generate smaller versions, made for usage in forums like this.
However, the problem is that for some very strange reason I am getting not only size-reduced images, but also color-reduced images! Who can help?
Here's the PHP code I use:
[PHP] $MyWhat=$_GET['What']; // Getting parameters
$MyWidth=$_GET['Width'];
$MyOriginalImage=imagecreatefromjpeg($MyWhat); // Reading measures of original image
$MyOriginalWidth=imagesx($MyOriginalImage);
$MyOriginalHeight=imagesy($MyOriginalImage);
$MyFactor=bcdiv($MyOriginalWidth,$MyWidth,2); // Calculating new height to given new width
$MyResizedHeight=bcdiv($MyOriginalHeight,$MyFactor,0);
$MyResizedImage=imagecreate($MyWidth,$MyResizedHeight); // Producing new resized image
$farbe_body=imagecolorallocate($MyResizedImage,255,255,255 );
imagecopyresized($MyResizedImage,$MyOriginalImage,0,0,0,0,$MyWidth,$MyResizedHeight,$MyOriginalWidth,$MyOriginalHeight);
// echo imagecolorstotal($MyResizedImage);
imagejpeg($MyResizedImage);[/PHP]
And here's the URL:
URL: jamaica-focus.com/SvenLittkowski/p/ImagesDisplayRemote.php5?What=../v/Lib/Nature/ID/01/100_5322 - 72DPI - 3000x2000px.jpg&Width=1000
