Jump to content

[SOLVED] How To Save Downloaded Image


stevesimo

Recommended Posts

Hi, I have a php function which downloads an image in PNG format from a remote server and returns the result as a value called $content.

 

Using the following code I can output the downloaded PNG image to the screen.

 

  header("Content-type: image");
  print($content);

 

My question is how can I store this PNG file on the server as an image file?

 

Many thanks, Steve (Blackpool, UK)

Link to comment
https://forums.phpfreaks.com/topic/119799-solved-how-to-save-downloaded-image/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.