[Zope] Newbie <dtml-if> question

jensebaer jensebaer@hotmail.com
Thu, 6 Apr 2000 20:52:36 +0200


 Use
<dtml-if "picture">
    do someting<br>
</dtml-if>

That doesn´t work because you handle with objekts and not with files.
S ".jpg"is only the id of the object and cannot be devided in that way. The
typ of the fobject is set by the content property and depends on the object.
you can name your image object with only a arbitrary numeric like "234" or
"1" or something like this

<dtml-if "'<dtml-var id>.jpg' in somelist">

Use this if you want to list all images in your directory.
<dtml-in "objectItems('Image')" sort=id>
    <dtml-var sequence-item>
</dtml-in>


----- Original Message -----
From: Stuart Foster <stuartf@MediServe.com>
To: <zope@zope.org>
Sent: Donnerstag, 6. April 2000 20:30
Subject: [Zope] Newbie <dtml-if> question


> I have the following statement:
>
> <dtml-if "'<dtml-var id>.jpg' in somelist">
>   DoSomething
> </dtml-if>
>
> id is some arbitrary numeric value that will change.
>
> Is the If tag being resolved to: <dtml-if "'1.jpg' in somelist">
> or <dtml-if "<dtml-var id>.jpg in somelist">
>
>
> Thanks
>
> Stuart Foster
> MediServe Information Systems
>
> > http://www.mediserve.com
> >
>
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> 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 )
>
>