[Zope] Using <dtml-return...>
McDonnell, Larry
lmcdonnell at protonenergy.com
Thu Oct 14 09:56:02 EDT 2004
Hi,
If you are using zope's acl I have used this.
<dtml-let user="REQUEST['AUTHENTICATED_USER']"
userid="user.getUserName()"
>
<dtml-unless "user.hasRole( this(), ['Manager'] )">
<dtml-unless "userid == REQUEST['name']">
<dtml-raise type="Naughty, Naughty!"> You aren't &dtml-name;, you are
&dtml-userid;! </dtml-raise>
</dtml-unless>
</dtml-unless>
<dtml-call "REQUEST.set( 'roles', user.getRoles() )">
<dtml-call "REQUEST.set( 'domains', user.getDomains() )">
<dtml-call "acl_users.manage_users( 'Change', REQUEST )">
</dtml-let>
Larry
-----Original Message-----
From: Laura McCord [mailto:Laura.McCord at doucet-austin.com]
Sent: Thursday, October 14, 2004 9:48 AM
To: zope at zope.org
Subject: [Zope] Using <dtml-return...>
Hi,
I have a form in a zope page template and when the form is submitted it
uses a dtml method to process this form. In the dtml method I have this:
<dtml-let msg="ValidateForm(username = username, curpasswd=curpasswd,
passwd1=passwd1, passwd2 = passwd2)">
<dtml-return msg>
</dtml-let>
How do I send this back to the page that contains the form? I read that
you use dtml-return but how do I display the results in the zope page
template.
Thanks,
Laura
_______________________________________________
Zope maillist - Zope at zope.org
http://mail.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding! **
(Related lists -
http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )
More information about the Zope
mailing list