<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><DIV><FONT size=2>
<P>From: Jonathan &lt;dev101@...&gt;</P>
<P>&nbsp;</P>
<P>&gt; targetFolder = string.join(traverse_subpath, '/') #you will have to play with this to get the right target folder for your app</P>
<P>&gt; aFolder = context.restrictedTraverse(targetFolder)</P>
<P>&gt; searchRes = aFolder.Catalog(&lt;some search string here&gt;)</P>
<P>&gt; &lt;do something with search results here&gt;</P>
<P>&nbsp;</P>
<P>First of all, thank you very much for your help.</P>
<P>I'm confused. I had a programmer working for me that wrote the following code:</P>
<P>&nbsp;</P>
<P>return 0</P>
<P>catalog = ''</P>
<P>try:</P>
<P>&nbsp;&nbsp;&nbsp; catalog = getattr(context, context.superValues('ZCatalog')[0].id)</P>
<P>except AttributeError:</P>
<P>&nbsp;&nbsp;&nbsp; pass</P>
<P></P>
<P>if catalog:</P>
<P>return 1</P>
<P>&nbsp;</P>
<P>Now, that works just fine if I leave the page template that calls it in the folder of a specific Web site. But when I put that template in a "root" folder that all the Web sites of the portal can call, it only gives me a printout of the tree of what's in the root folder. What I'm trying to accomplish is that it gives me the tree of the specific Web site folder from which it is called.</P>
<P>&nbsp;</P>
<P>My problem is that I frankly don't understand what my programmer wrote...how it works. Research taught me that "superValues" returns the meta_data of ZCatalog, we're popping the first element of the tuple, getting it's ID, all in context of the call, and calling that a catalog. But why do we return "1" if we get a catalog? How does that print the catalog? Then, how do I incorporate your information to achieve my goal?</P>
<P>Thanks for any help you care to offer,</P>
<P>Javier</P></FONT></DIV></div><br>

<hr size=1>Need a quick answer? Get one in minutes from people who know. Ask your question on
 <a href="http://answers.yahoo.com/;_ylc=X3oDMTFvbGNhMGE3BF9TAzM5NjU0NTEwOARfcwMzOTY1NDUxMDMEc2VjA21haWxfdGFnbGluZQRzbGsDbWFpbF90YWcx">Yahoo! Answers</a>.</body></html>