Mike Bannister wrote:
> Just for the heck of it I dropped that same code into a DTML Document in the
> same Folder and it didn't list the Files as I had expected. I understand
> pretty much the differences of Methods and Documents and I'm assuming the
> reason for this is related to the way the Documents exists in it's own
> namespace and the Method doesn't... so my best guess for this behavior is
> that the 'scope' of objectValues() is limited to the current namespace.
> 
> Am I even close? If not can someone explain this to me?

This is quite a thorny FAQ. The root of it is the binding of methods to
objects/namespaces in DTML, which has had lots of press on
[EMAIL PROTECTED] recently.

The short version is:

-if that code is in a method, it is executed on the method's container
(actualyl acquisition context, but don't worry abotu that too much ;-)
-if the code was in a documents, it is executed on that document. Since
documents can't really have things attached to them that would be
returned by objectValues, you usually get an empty list back :-)

HTH,

Chris

_______________________________________________
Zope maillist  -  [EMAIL PROTECTED]
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 )

Reply via email to