[Zope] Acquisition not working as expected
Andrew Milton
akm at theinternet.com.au
Fri Mar 3 03:26:10 EST 2006
+-------[ Roman Klesel ]----------------------
| Andrew Milton schrieb:
| >
| > Perhaps if you describe the problem you're trying to solve, we can actually
| > help you.
| >
|
| Yes, thank you!
| just as in my example above I want to be able to call this methods on any File objects from a ZPT like this:
|
| <ul>
| <li tal:repeat="elem context/objectValues"
| <img tal:attributes="src string: ${elem/absolute_url}/genGraph"> plot </img>
| </li>
| <ul>
In what way doesn't this work? I've certainly used this pattern in my FS
products without problems.
| 'self' inside the a Zope product is the _same_ as 'context' or 'here' within
| ZPT or PythonScripts.
It IS in the context of that object. However, if you call a method that is
acquired, self in that method is the acquired object, not the acquiring object.
--
Andrew Milton
akm at theinternet.com.au
More information about the Zope
mailing list