[Zope] Newbie question re referring to items
Dieter Maurer
dieter@handshake.de
Mon, 11 Feb 2002 21:11:48 +0100
Gupta, Anu writes:
> Feel stupid for asking this question, but can't work it out...
Did you read the Zope book or
<http://www.dieter.handshake.de/pyprojects/zope/book/chap3.html>?
> Given a folder structure similar to the following:
>
> /
> test
> images
> content
>
>
> How does a dtml document in /test/content obtain an image from the
> /test/images folder, without using the <img...> tag. I want to be able to
> get it using <dtml-var ...>
Background reading will tell you about the following options:
* "<dtml-with images><dtml-var myimage></dtml-with>"
* '<dtml-var expr="restrictedTraverse(path_to_your_image)">'
* '<dtml-var expr="images[name_of_your_image_as_string]">'
* '<dtml-var expr="images.your_image">'
Read a bit, learn about the various restrictions
and select the best alternative for you.
Dieter