Newbie: How to download a JPG file from the internet....?

John Branthoover jbranthoover at yahoo.com.NOSPAM
Mon Sep 17 16:39:18 EDT 2001


Hello All,
    Can anyone tell me how to download an image from a web site?
An example:
<IMG SRC="./images/getme.jpg"> that is located at www.somewhere.org

    I have already found the urllib module and have used the urlopen
function to create a string from a web page,  but I don't know how to
proceed from here.  I can isolate the string -  <IMG
SRC="./images/getme.jpg">, but then what?  I would like to eventually write
it to a file on my local drive.  Any information will be greatly
appreciated.  Thank you for your time.






More information about the Python-list mailing list