[Zope] Getting properties of objects

Daniel Rusch drusch@globalcrossing.com
Thu, 28 Sep 2000 13:21:12 -0500


I am trying to build a property seach engine that will search an entire
Zope site for a names property (i.e. color) and it would return a list
of all objects with that property and it's corresponding value.
Addtionally, as an option, I would like to display all properties of all
objects (i.e. pass in a wild card instead of a name and you get all
properties in the site).

I started on the wild card requirement first:
I have been able to get all the properties of the root level folders,
but not the the DTML Documents in the root level. Additionally, I
haven't been able to recurse into the sub folders. 

Any thoughts????

Dan 

<dtml-if "property=='*'">
<dtml-call "REQUEST.set('num','1')">
<table>
<th colspan=1 align=left><b><u>Object</u></b></th><th
colspan=1><b><u>Property</u></b></th><th
colspan=1><b><u>Value</u></b></th>
<dtml-in "objectValues('Folder')">
	<tr align=left><td valign=top><b><dtml-var num>:&nbsp;<dtml-var
id>&nbsp;</b></td>
	<dtml-in "_[id].propertyItems()">
	<td valign=top>
              <dtml-var sequence-key></td><td><dtml-var
sequence-item></td></tr>
		<tr><td colspan=1>&nbsp;</td>
        </dtml-in></tr>
	<dtml-call "REQUEST.set('num',_.int(num)+1)">
</dtml-in>
</table>
</dtml-if "property=='*'">