-----BEGIN PGP SIGNED MESSAGE-----
Rocky Burt wrote:
> I'd like to add a new variable to the TALES namespace for all actions
> (for all existing action providers) on a CMF 1.6.0 site. We basically
> have a view that provides some global vars that we'd like to expose.
> Does anyone know of a sensible way to do this without monkey patching
> CMFCore.Expression.createExprContext ?
> Or perhaps suggest a different way of accomplishing what we need?
The expression contexts for objects are cached in the request, so you
could attempt to preempt calling 'createExprContext' by jamming your own
context into that cache (e.g., during publishing traversal, or at least
before calling 'listFilteredActionsFor').
I originally intended to have the actiosn tool construct the context and
pass it in to the providers, which would have allowed you to customize
the contexts by replacing the actions tool. I don't recall why we ended
up with the caching strategy we have now.
Tres Seaver +1 202-558-7113 [EMAIL PROTECTED]
Palladion Software "Excellence by Design" http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
Zope-CMF maillist - Zope-CMF@lists.zope.org
See http://collector.zope.org/CMF for bug reports and feature requests