I am taking my first tentative steps in using the gd library with the problem of taking an image and magnifying it four times and storing both in seperate files and showing the results to the browser.
However i get an error coming from the ImageGif() function which states that it is unable to open a gif file for writing.
I then wrote in a line before this
fopen(\"...\", \"w+\");
which resulted in an error message permission denied.
Here is the modified code
<?
$size = GetImageSize(\"logoBefore.gif\");
$imageIn = ImageCreateFromGif(\"logoBefore.gif\");
$imageOut = ImageCreate($size[0] 4, $size[1] 4);
ImageCopyResized($imageOut,$imageIn,0,0,0,0,$size[0] 4,$size[1] 4, $size[0], $size[1] );
fopen(\"logoAfter.gif\",\"w+\");
ImageGif($imageOut, \"logoAfter.gif\");
ImageDestroy($imageIn);
ImageDestroy($imageOut);
?>
<IMG SRC=\"logoBefore.gif\" BORDER=0>
<IMG SRC=\"logoAfter.gif\" BORDER=0>
Any thoughts would be kindly appreciated
Paul