Hi!<br>Thanks Martijn and Matt for your ideas!<br>@Matt: can you explain with more detail the question about REQUEST.response.write()? If the written content is as long as a file like prototype is not a very heavy solution?
<br><br>The contents of the zexp file are only js files and images (static content) and I&#39;m using Zope2<br><br>What about the functionality of the freemind view? What do you think about?<br><br>Thanks!<br><br><div><span class="gmail_quote">
2008/1/11, Matt Hollingsworth &lt;<a href="mailto:mr.hworth@gmail.com">mr.hworth@gmail.com</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br><br>This sounds like the same problem I presented earlier.&nbsp;&nbsp;Are you using zope<br>2.x?&nbsp;&nbsp;If so, then it will only take you ~30 minutes to code something that<br>makes use of REQUEST.response.write().&nbsp;&nbsp;That&#39;s what I ended up doing; I
<br>wrote a simple class that would mount a directory on the file system and<br>just serve the files that are in that directory.&nbsp;&nbsp;If you make use of<br>globals()[&quot;__file__&quot;], you can make the class independent of absolute
<br>locations.<br><br>If you are using zope 3 (I&#39;m not sure if you can easily get this<br>functionality out of five + zope2.x, since this deals with the publisher...<br>someone else would have to answer that), look at this site:
<br><a href="http://apidoc.zope.org/++apidoc++/Book/zopepublisherhttpresults.txt/show.htm">http://apidoc.zope.org/++apidoc++/Book/zopepublisherhttpresults.txt/show.htm</a><br>l<br><br>Basically, it appears you can just return a file reference and let the
<br>publisher deal with the rest.<br><br>A filesystem-based solution, as opposed to a ZODB way of doing this sort of<br>thing, seems to be the best way to go as far as I&#39;m concerned.<br><br>If you are, indeed, using zope2.x
, and want to go the response.write() route<br>look at OFS/Image.py for an example of the serving logic if you want to<br>avoid putting everything in memory.<br><br>There may be better ways to do this sort of thing, but at least this is one
<br>way of going about it that worked nicely for me!<br><br>-Matt<br><br>-----Original Message-----<br>From: <a href="mailto:zope-bounces@zope.org">zope-bounces@zope.org</a> [mailto:<a href="mailto:zope-bounces@zope.org">
zope-bounces@zope.org</a>] On Behalf Of<br>Garito<br>Sent: Friday, January 11, 2008 6:33 AM<br>To: Zope user list<br>Subject: [Zope] The best way<br><br>Hi, all!<br>If you have download the ZSM product you could see I put on it a zexp
<br>file with prototype and some other js file and a css file plus images<br><br>This was only a prototype solution to bring you the chance to see how<br>my ideas are but I think this is not a definitive solution<br><br>Now my question:
<br><br>Which is the best zope way to serve this kind of files trying to avoid<br>any other product dependence?<br><br>Thanks a lot!<br>--<br>Mis Cosas<br><a href="http://blogs.sistes.net/Garito">http://blogs.sistes.net/Garito
</a><br>_______________________________________________<br>Zope maillist&nbsp;&nbsp;-&nbsp;&nbsp;<a href="mailto:Zope@zope.org">Zope@zope.org</a><br><a href="http://mail.zope.org/mailman/listinfo/zope">http://mail.zope.org/mailman/listinfo/zope
</a><br>**&nbsp;&nbsp; No cross posts or HTML encoding!&nbsp;&nbsp;**<br>(Related lists -<br> <a href="http://mail.zope.org/mailman/listinfo/zope-announce">http://mail.zope.org/mailman/listinfo/zope-announce</a><br> <a href="http://mail.zope.org/mailman/listinfo/zope-dev">
http://mail.zope.org/mailman/listinfo/zope-dev</a> )<br><br></blockquote></div><br><br clear="all"><br>-- <br>Mis Cosas<br><a href="http://blogs.sistes.net/Garito">http://blogs.sistes.net/Garito</a><br>Zope Smart Manager<br>
<a href="http://blogs.sistes.net/Garito/670">http://blogs.sistes.net/Garito/670</a>