[Zope] Dowloading images from another site with external method?

2001-01-24 Thread Etienne Labuschagne

Hi all

I have an external Python method in Zope that accesses a map server through
an ActiveX connector.  This map server creates a map and gives me the URL
where I can download the map eg.
"http:\\www.mysite.com\images:8081\img1234545.png"

I want to download this image with the method, put it in a folder on my Zope
server's disk, do some image processing with PIL and then upload it into my
Zope site.

My problem is that I don't know how to download the image from the URL
above!  I can have zope display it from that address, but that won't work as
the map server eventually deletes the rendered maps (also I want to edit it
first) I cannot use ftplib as the map server does not handle ftp requests,
only http.  I don't know how to use the httplib (or whatever) to download
that image to my disk.

Any help?  

Thanks
Etienne

Tel: (012) 348 4586
Cel: 082 442 8981
Fax: (012) 361 8355


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Dowloading images from another site with external method?

2001-01-24 Thread Oleg Broytmann

On Wed, 24 Jan 2001, Etienne  Labuschagne wrote:
 "http:\\www.mysite.com\images:8081\img1234545.png"

   Incorrect slashes in the URL. It seems M$ is destroying people's brains :(
   Use right slashes ///

 My problem is that I don't know how to download the image from the URL

   Use urllib.urlretrieve. Or use external program that can download files
from URL. lynx, e.g. (I think, there is lynx for Win; certainly, there are
other tools.)

Oleg.

 Oleg Broytmann http://www.zope.org/Members/phd/ [EMAIL PROTECTED]
   Programmers don't die, they just GOSUB without RETURN.


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )