[Zope-CMF] Re: CMFFormController & TALES
Geoff Davis
geoff at geoffdavis.net
Fri Sep 5 09:07:48 EDT 2003
Sorry -- that should have been
python:object.getParentNode().absolute_url()
Alternatively, if you want the first folderish parent, you could try
python:folder.absolute_url()
Note that "context" is not defined in the list of available items:
'object_url': object_url,
'folder_url': folder.absolute_url(),
'portal_url': portal.absolute_url(),
'object': context,
'folder': folder,
'portal': portal,
'nothing': None,
'request': getattr( context, 'REQUEST', None ),
'modules': SecureModuleImporter,
'member': member,
'state': controller_state,
Geoff
"grendelAI" <grendelAI at msn.com> wrote in message
news:bj695u$nq3$1 at sea.gmane.org...
> Thanks for the info. Unfortunately, adding
>
> > python:context.getParentNode().absolute_url()
>
> gives me an error that context is not defined.
>
>
> Perhaps I am wrong in assuming that the CMFFormController metadata
property
> file supports
> the complete TALES functionality. Below is the file as I have changed it
per
> your suggestion:
>
> [default]
> title=Invite Form
>
> [validators]
>
> [actions]
> action.success..send = traverse_to:string:sendInvites
> action.success..cancel =
> redirect_to:python:context.getParentNode().absolute_url()
>
> Let me know if you have another suggestion.
>
>
> _______________________________________________
> Zope-CMF maillist - Zope-CMF at zope.org
> http://mail.zope.org/mailman/listinfo/zope-cmf
>
> See http://collector.zope.org/CMF for bug reports and feature requests
>
More information about the Zope-CMF
mailing list