[Zope] question on objectValues

Peter Millar peter.millar at parasyn.com.au
Wed Jan 19 22:18:37 EST 2005


holden,

I don't know how to do this in dtml but in zpt I can create variables so
rather than doing path="wombat/&dtml-id;/" I would in zpt anyway do a
tal:define="mypath python:'wombat/'+getID()+'/'" and then have <folder
path="" tal:attribute="path mypath"

Can you do something similar in dtml??


____________________________________________ 
Peter Millar 

-----Original Message-----
From: zope-bounces+peter.millar=parasyn.com.au at zope.org
[mailto:zope-bounces+peter.millar=parasyn.com.au at zope.org] On Behalf Of
Wombie Tomek
Sent: Thursday, 20 January 2005 13:00
To: zope at zope.org
Subject: [Zope] question on objectValues


I've trying to write a little dtml method that will out put a list of
images in a given location using a variable "path" with is passed from a
form.  ?path=photos1...

but haven't had much luck because it doesn't seems to interpret the
variable i want to be a path.  if i put the path directly into the
program ie "photos1.objectValues()" it works.  but i need it to be feed
from a variable path.

<dtml-in expr="path.objectValues('CMF ZPhotoSlides')">

<folder path="wombat/&dtml-id;/" name="&dtml-title_or_id;"
amount="<dtml-in expr="objectValues(['CMF ZPhoto'])"><dtml-if
sequence-end><dtml-var
count-description></dtml-if></dtml-in>"/>

</dtml-in>

this should simple ;-)  but i'm missing something.

thanks...

holden
_______________________________________________
Zope maillist  -  Zope at zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )



More information about the Zope mailing list