I try the following simple code and somehow it just doesnt work.![]()
Any ideas greatly appreciated
PHP Code:<?php
$file = 'C:\Program Files\Apache Group\Apache2\htdocs\hard_disk.jpg';
$saveAs = 'C:\Program Files\Apache Group\Apache2\htdocs\newhard_disk.jpg';
IMResize( $file, $saveAs, 10, 10 );
function IMResize( $file, $saveAs, $width, $height )
{
$source = file_get_contents( $file );
$handle = fopen( $saveAs, 'w' );
fwrite( $handle, $source );
$cmd = "C:\Program Files\ImageMagick\mogrify -resize $width x $height " . $saveAs;
exec( $cmd );
}
?>







Bookmarks