[Zope] Re: Subclass and Image

Nico Grubert nico@beehive.de
Fri, 22 Jun 2001 10:55:16 +0100


> From: "Laurie Nason" <laurien@tiger.bcm.tmc.edu>
> To: "Zope" <zope@zope.org>
> Date: Thu, 21 Jun 2001 11:13:30 -0500
> Subject: [Zope] Subclass and Image
> 
> Ok guys & gals,
> Totally stupid question but probably easy to answer if you've done it
> before!!!
> I have a zclass created, for which I chose OFSImage when I created it. I
> then added a couple of properties and now would like to get the image out.
> When I create a class instance I can get the properties out no problem, but
> cannot anywhere find out how to get the image to display on my web page...
> Any help would be much appreciated...
> Laurie
> 
> Laurie Nason
> Dept. of Biochemistry - N420
> Baylor College of Medicine
> Houston. TX77030
 


displaying a single instance:

<dtml-var "Instance_id.Property_id">

example:
<dtml-var "MyInstance.MyImage">

note: "myImage" is an Subobject since the ZClasses has the Base Class "Z
CLass : Object Manager"


displaying all instances:

<dtml-in "PARENTS[0].objectValues(['ZCLASS_META_TYPE'])" sort=Titel>
   <dtml-var id> - 
   <dtml-in "objectValues('Image')">
       <dtml-var sequence-item>
   </dtml-in><br>
</dtml-in>
               

hope this helps,

Nico

----------------------------------------------------------------
nico grubert  (education & publishing)    nico@beehive.de
beehive elektronische medien GmbH         http://www.beehive.de
phone: +49 30 847-82 0                    fax: +49 30 847-82 299