Download jpg file to local computer

Discussion in 'PHP' started by ssimon171078, Mar 9, 2015.

  1. #1
    How can download jpg file to my localhost using PHP ,i think to use
    file_put_contents
    i started to write some code:
    <?php
    file_put_contents('1.jpg','http://i04.fotocdn.net/s3/60/gallery_m/69/2328118331.jpg' );
    ?>
    PHP:
    i need to save jpg file from http://i04.fotocdn.net/s3/60/gallery_m/69/2328118331.jpg to local folder.
     
    ssimon171078, Mar 9, 2015 IP
  2. shureg

    shureg Active Member

    Messages:
    18
    Likes Received:
    2
    Best Answers:
    1
    Trophy Points:
    80
    #2
    here is some solutions
    http://stackoverflow.com/questions/3938534/download-file-to-server-from-url
     
    shureg, Mar 9, 2015 IP
  3. mohanprakash

    mohanprakash Greenhorn

    Messages:
    47
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #3
    Here You can see the solution of your problem

    http://stackoverflow.com/questions/9801471/download-image-from-url-using-php-code
     
    mohanprakash, Mar 9, 2015 IP