[Zope] Hacking filenames in http headers?
Garikoitz Araolaza
gari@eibar.org
Wed, 07 Aug 2002 12:52:21 +0200
Hi!
I'm using a DTML method to get an XML view from a ZClass object.
What I'm trying to do, is that when the user requests the address:
http://www.mysite.com/Objects/MyObject/xml
he/she gets an xml file with the ID MyObject.xml so that he can save it
cleanly in his filesystem (or open it with his browser), so that he/she
doesn't end up having thousands of files called simply 'xml'.
I've thought that a header like:
<dtml-call "RESPONSE.setHeader('content-type', 'text/xml')">
could be a solution if HTTP protocol would have it... But I also think that
it wouldn't be very clear for HTTP protocol to have one filename for the
URL and a different one for the reply to the user.
Any hint?
Thanks!!
Gari
_________________________________________
Garikoitz Araolaza
gari@eibar.org