Nomax5 Posted August 23, 2006 Share Posted August 23, 2006 Hi,On one of my hosts the code below works but on the other I can an error, I am wondering if it’s a permissions thing.It also works fine outputting to the browser but when I try to output the gif to a file I get this error:<br /><b>Warning</b>: imagegif(): Unable to open 'images/canvasfile.gif' for writing in <b>/nfsn/content/blinkingphoto/htdocs/test.php</b> on line <b>4</b><br />this is the code any ideas? [code]<?php header ("Content-type: image/gif"); $canvas = imagecreatefromgif("images/bird1.gif"); imagegif($canvas,"images/canvasfile.gif"); imageDestroy($canvas); echo "file created";?>[/code]I am not very familiar with setting up stuff like this. Quote Link to comment Share on other sites More sharing options...
SammyP Posted August 23, 2006 Share Posted August 23, 2006 Is it to do with the folder permissions in your respective 'images' directories? I always forget to change them so I can create thumbnails, and have set up code to remind me now.Sam. Quote Link to comment Share on other sites More sharing options...
Nomax5 Posted August 23, 2006 Author Share Posted August 23, 2006 my images folder is set to 755 on both hosts Quote Link to comment Share on other sites More sharing options...
SammyP Posted August 23, 2006 Share Posted August 23, 2006 Darn.Not much more I can think of. Could be something to do with gifs? Some hosts don't load the software for those. I think there is some licensing issue. Probably way off here. Can you create a text file on both?Sorry not to be of any more help here. Quote Link to comment Share on other sites More sharing options...
Nomax5 Posted August 23, 2006 Author Share Posted August 23, 2006 I contacted my host and it suddenly started working I guess it was a set up thingor something so newbie they didn't want to embarress me lol.thanks for your help SammyP much appreciated. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.