[Zope] DTML to search a lines property in a DTML Document?

complaw@hal-pc.org complaw@hal-pc.org
Wed, 6 Jun 2001 21:16:32 GMT


Dan:

First, thanks for what you did.  Just a quick question, is the Prop property
that you tested a lines or a string?

Thanks again,

Ron


> Here you go
> 
> <dtml-in "objectItems(['DTML Document'])">
>   <dtml-with sequence-item>
> 	<dtml-in "propertyItems()">
>               	<dtml-if "_['sequence-key'] == 'Prop'">
> 			<dtml-comment> Put your test code here</dtml-comment>
> 	 		<dtml-var sequence-item><br>
> 		</dtml-if>
>         </dtml-in>
>   </dtml-with>
> </dtml-in>
> 
> 
> I made a folder and put three DTML Documents in it, they all had a
> property called Prop thus the line <dtml-if "_['sequence-key'] ==
> 'Prop'"> (change 'Prop' to suit your needs.
> 
> HTH
> 
> Dan
> 
> complaw@hal-pc.org wrote:
> > 
> > > Are all of the documents in a specific folder or are they all over the
> > > place???
> > >
> > 
> > All in the same folder.
> > 
> > Ron
> > >
> > >
> > > complaw@hal-pc.org wrote:
> > > >
> > > > Can you, using DTML, search a lines property of a DTML Document to look
for
> > a
> > > > specific string?  I have a set of DTML Documents with a custom lines
> > property
> > > > (called, e.g., "doctrines") and I want to search through the list in the
> > context
> > > > of a conditional statement in order to filter out the DTML Documents
that
> > don't
> > > > have a specific doctrine in the doctrines property (or list those that
do).
> > > >
> > > > Has anyone ever done that or something similar?
> > > >
> > > > TIA,
> > > >
> > > > Ron
> > > >
> > > > _______________________________________________
> > > > 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
> > >
> 
> _______________________________________________
> 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 )
>