Anim9or Posted July 3, 2009 Share Posted July 3, 2009 Hi again, What would be the best way to save a picture just created to the FTP server in PHP. Right now I'm using this code: $my_img = imagecreatefromjpeg("images/Goldie.jpg"); $background = imagecolorallocate( $my_img, 0, 0, 255 ); $text_colour = imagecolorallocate( $my_img, 255, 255, 0 ); $line_colour = imagecolorallocate( $my_img, 128, 255, 0 ); imagestring( $my_img, 4, 30, 25, "thesitewizard.com", $text_colour ); imagesetthickness ( $my_img, 5 ); imageline( $my_img, 30, 45, 165, 45, $line_colour ); header( "Content-type: image/jpeg" ); //imagejpeg( $my_img ); imagecolordeallocate( $line_color ); imagecolordeallocate( $text_color ); imagecolordeallocate( $background ); imagedestroy( $my_img ); Thanks! Link to comment https://forums.phpfreaks.com/topic/164609-save-a-picture-to-the-server/ Share on other sites More sharing options...
xtopolis Posted July 3, 2009 Share Posted July 3, 2009 What about this? rename See the example Link to comment https://forums.phpfreaks.com/topic/164609-save-a-picture-to-the-server/#findComment-868154 Share on other sites More sharing options...
Anim9or Posted July 3, 2009 Author Share Posted July 3, 2009 What exactly do I put in as the old file though? I tried using the original path but it just saved the original file and no the edited one, so I tried $my_img an dall that came up on screen was the link. Link to comment https://forums.phpfreaks.com/topic/164609-save-a-picture-to-the-server/#findComment-868202 Share on other sites More sharing options...
xtopolis Posted July 3, 2009 Share Posted July 3, 2009 Show some relevant code please. Link to comment https://forums.phpfreaks.com/topic/164609-save-a-picture-to-the-server/#findComment-868505 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.