-----Original Message----- From: Ethan Fremen [mailto:mindlace@majordomo.net] Sent: Wednesday, December 08, 1999 4:25 PM To: zope-dev@zope.org Subject: [Zope-dev] request: FTP
The BASE and URL are great. I'd love, however, to be able to say FTP0 and get the same behavior as BASE0 or URL0 (take yer pick) but with ftp:// on the front instead of http://
could someone point to where I could hack this?
What happens though when the HTTP side of Zope supports multi-hosting (as it will in 2.2) and the FTP side doesn't? When you start putting protocol specific widgets at the application layer (which is supposed to protocol independant) expect to be bitten somewhere, at some time. I would love to be able to, for example, detect when a method is being called by XML-RPC instead of HTTP, but it just can't be done, and it *shouldn't* be done, because all information pertaining to the protocol should be abstracted out at the application. -Michel
Michel Pelletier wrote:
What happens though when the HTTP side of Zope supports multi-hosting (as it will in 2.2) and the FTP side doesn't? When you start putting protocol specific widgets at the application layer (which is supposed to protocol independant) expect to be bitten somewhere, at some time.
But isn't BASE/URL protocol dependant? i.e., should it not return just the path, and not http:// ? That way, I could just say <a href="ftp://&dtml-url0">download this page</a> and everything would be hunky-dory, _assuming_ I'm not worried about multi-hosting. On the subject of multi-hosting, shouldn't a FTP0 be intelligent enough to go where the file is actually hosted? So there may be www.spam.com and www.niknights.com but only ftp.nicehost.net, so &dtml-FTP0 in file http://www.spam.com/myfile would be ftp://ftp.nicehost.net/myfile (note- i've obviously not looked at the code)
I would love to be able to, for example, detect when a method is being called by XML-RPC instead of HTTP, but it just can't be done, and it *shouldn't* be done, because all information pertaining to the protocol should be abstracted out at the application.
But doesn't BASE/URL violate what you're saying? or do I misunderstand how they work? I just was writing how-tos for my clients, and had to write a lot of "hard" ftp urls. I suppose I can just do a "download" method where I do a Content-type: application/octet-stream and then call the related url. -- Ethan "mindlace" Fremen you cannot abdicate responsibility for your ideology.
participants (2)
-
Ethan Fremen -
Michel Pelletier